Use constant instead of magic number
Signed-off-by: Morris Jobke <hey@morrisjobke.de>
This commit is contained in:
parent
3606b4a8ba
commit
7f49492117
|
@ -193,7 +193,7 @@ class OwnershipTransferService {
|
|||
$output->writeln('Validating quota');
|
||||
$size = $view->getFileInfo($sourcePath, false)->getSize(false);
|
||||
$freeSpace = $view->free_space($destinationUid . '/files/');
|
||||
if ($size > $freeSpace && $freeSpace !== -2) {
|
||||
if ($size > $freeSpace && $freeSpace !== FileInfo::SPACE_UNKNOWN) {
|
||||
$output->writeln('<error>Target user does not have enough free space available.</error>');
|
||||
throw new \Exception('Execution terminated.');
|
||||
}
|
||||
|
|
Loading…
Reference in New Issue