|
@@ 270-278 (lines=9) @@
|
| 267 |
|
} |
| 268 |
|
} catch (AlreadyExistsException $e) { |
| 269 |
|
$this->swallow(__FUNCTION__, $e); |
| 270 |
|
if ($this->unlink($target)) { |
| 271 |
|
$result = $this->share->rename($this->root . $source, $this->root . $target); |
| 272 |
|
if ($result) { |
| 273 |
|
$this->removeFromCache($this->root . $source); |
| 274 |
|
$this->removeFromCache($this->root . $target); |
| 275 |
|
} |
| 276 |
|
} else { |
| 277 |
|
$result = false; |
| 278 |
|
} |
| 279 |
|
} catch (Exception $e) { |
| 280 |
|
$this->swallow(__FUNCTION__, $e); |
| 281 |
|
// Icewind\SMB\Exception\Exception, not a plain exception |
|
@@ 283-291 (lines=9) @@
|
| 280 |
|
$this->swallow(__FUNCTION__, $e); |
| 281 |
|
// Icewind\SMB\Exception\Exception, not a plain exception |
| 282 |
|
if ($e->getCode() === 22) { |
| 283 |
|
if ($this->unlink($target)) { |
| 284 |
|
$result = $this->share->rename($this->root . $source, $this->root . $target); |
| 285 |
|
if ($result) { |
| 286 |
|
$this->removeFromCache($this->root . $source); |
| 287 |
|
$this->removeFromCache($this->root . $target); |
| 288 |
|
} |
| 289 |
|
} else { |
| 290 |
|
$result = false; |
| 291 |
|
} |
| 292 |
|
} elseif ($e->getCode() === 16) { |
| 293 |
|
$this->swallow(__FUNCTION__, $e); |
| 294 |
|
$result = false; |