|
|
|
|
@ -238,7 +238,7 @@ abstract class StoragesController extends Controller { |
|
|
|
|
* |
|
|
|
|
* @param StorageConfig $storage storage configuration |
|
|
|
|
*/ |
|
|
|
|
protected function updateStorageStatus(StorageConfig &$storage) { |
|
|
|
|
protected function updateStorageStatus(StorageConfig &$storage, $origin = null) { |
|
|
|
|
try { |
|
|
|
|
$this->manipulateStorageConfig($storage); |
|
|
|
|
|
|
|
|
|
@ -249,7 +249,8 @@ abstract class StoragesController extends Controller { |
|
|
|
|
\OC_Mount_Config::getBackendStatus( |
|
|
|
|
$backend->getStorageClass(), |
|
|
|
|
$storage->getBackendOptions(), |
|
|
|
|
false |
|
|
|
|
false, |
|
|
|
|
$origin |
|
|
|
|
) |
|
|
|
|
); |
|
|
|
|
} catch (InsufficientDataForMeaningfulAnswerException $e) { |
|
|
|
|
@ -293,11 +294,11 @@ abstract class StoragesController extends Controller { |
|
|
|
|
* |
|
|
|
|
* @return DataResponse |
|
|
|
|
*/ |
|
|
|
|
public function show($id) { |
|
|
|
|
public function show($id, $origin = null) { |
|
|
|
|
try { |
|
|
|
|
$storage = $this->service->getStorage($id); |
|
|
|
|
|
|
|
|
|
$this->updateStorageStatus($storage); |
|
|
|
|
$this->updateStorageStatus($storage, $origin); |
|
|
|
|
} catch (NotFoundException $e) { |
|
|
|
|
return new DataResponse( |
|
|
|
|
[ |
|
|
|
|
|