| @@ 519-528 (lines=10) @@ | ||
| 516 | } |
|
| 517 | } |
|
| 518 | ||
| 519 | public function isReadable($path) { |
|
| 520 | try { |
|
| 521 | $info = $this->getFileInfo($path); |
|
| 522 | return !$info->isHidden(); |
|
| 523 | } catch (NotFoundException $e) { |
|
| 524 | return false; |
|
| 525 | } catch (ForbiddenException $e) { |
|
| 526 | return false; |
|
| 527 | } |
|
| 528 | } |
|
| 529 | ||
| 530 | public function isUpdatable($path) { |
|
| 531 | try { |
|
| @@ 530-541 (lines=12) @@ | ||
| 527 | } |
|
| 528 | } |
|
| 529 | ||
| 530 | public function isUpdatable($path) { |
|
| 531 | try { |
|
| 532 | $info = $this->getFileInfo($path); |
|
| 533 | // following windows behaviour for read-only folders: they can be written into |
|
| 534 | // (https://support.microsoft.com/en-us/kb/326549 - "cause" section) |
|
| 535 | return !$info->isHidden() && (!$info->isReadOnly() || $this->is_dir($path)); |
|
| 536 | } catch (NotFoundException $e) { |
|
| 537 | return false; |
|
| 538 | } catch (ForbiddenException $e) { |
|
| 539 | return false; |
|
| 540 | } |
|
| 541 | } |
|
| 542 | ||
| 543 | public function isDeletable($path) { |
|
| 544 | try { |
|
| @@ 543-552 (lines=10) @@ | ||
| 540 | } |
|
| 541 | } |
|
| 542 | ||
| 543 | public function isDeletable($path) { |
|
| 544 | try { |
|
| 545 | $info = $this->getFileInfo($path); |
|
| 546 | return !$info->isHidden() && !$info->isReadOnly(); |
|
| 547 | } catch (NotFoundException $e) { |
|
| 548 | return false; |
|
| 549 | } catch (ForbiddenException $e) { |
|
| 550 | return false; |
|
| 551 | } |
|
| 552 | } |
|
| 553 | ||
| 554 | /** |
|
| 555 | * check if smbclient is installed |
|