mirror of
https://github.com/friendica/friendica
synced 2025-04-26 08:30:10 +00:00
Improve impossible exception-handler for storage move
This commit is contained in:
parent
14c97f7b62
commit
732992a296
2 changed files with 15 additions and 2 deletions
|
@ -240,8 +240,8 @@ class StorageManager
|
|||
*/
|
||||
public function move(Storage\IStorage $destination, array $tables = self::TABLES, int $limit = 5000)
|
||||
{
|
||||
if ($destination === null) {
|
||||
throw new Storage\StorageException('Can\'t move to NULL storage backend');
|
||||
if (!$this->isValidBackend($destination, true)) {
|
||||
throw new Storage\StorageException(sprintf("Can't move to storage backend '%s'", $destination::getName()));
|
||||
}
|
||||
|
||||
$moved = 0;
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue