mirror of
https://codeberg.org/icewind/SMB.git
synced 2026-06-03 17:24:07 +02:00
some code cleanup
This commit is contained in:
parent
adf5ec0e6d
commit
71e917bbae
10 changed files with 32 additions and 114 deletions
|
|
@ -13,23 +13,4 @@ class Rename extends Double {
|
|||
parent::__construct($connection);
|
||||
$this->command = 'rename';
|
||||
}
|
||||
|
||||
/**
|
||||
* @param $lines
|
||||
* @return bool
|
||||
*/
|
||||
protected function parseOutput($lines) {
|
||||
if (count($lines) === 0) {
|
||||
return true;
|
||||
} else {
|
||||
list($error,) = explode(' ', $lines[0]);
|
||||
switch ($error) {
|
||||
case 'NT_STATUS_OBJECT_PATH_NOT_FOUND':
|
||||
case 'NT_STATUS_OBJECT_NAME_NOT_FOUND':
|
||||
throw new \SMB\NotFoundException();
|
||||
default:
|
||||
throw new \Exception();
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue