diff options
-rw-r--r-- | lib/private/Share20/Manager.php | 2 | ||||
-rw-r--r-- | tests/lib/Share20/ManagerTest.php | 2 |
2 files changed, 2 insertions, 2 deletions
diff --git a/lib/private/Share20/Manager.php b/lib/private/Share20/Manager.php index db13a72e0bd..c7a42bbbf02 100644 --- a/lib/private/Share20/Manager.php +++ b/lib/private/Share20/Manager.php @@ -632,7 +632,7 @@ class Manager implements IManager { $mounts = $this->mountManager->findIn($path->getPath()); foreach ($mounts as $mount) { if ($mount->getStorage()->instanceOfStorage('\OCA\Files_Sharing\ISharedStorage')) { - throw new \InvalidArgumentException('Path contains files shared with you'); + throw new \InvalidArgumentException('You cannot share a folder that contains other shares'); } } } diff --git a/tests/lib/Share20/ManagerTest.php b/tests/lib/Share20/ManagerTest.php index 461bddf3db6..e69afda4ada 100644 --- a/tests/lib/Share20/ManagerTest.php +++ b/tests/lib/Share20/ManagerTest.php @@ -2273,7 +2273,7 @@ class ManagerTest extends \Test\TestCase { public function testPathCreateChecksContainsSharedMount() { $this->expectException(\InvalidArgumentException::class); - $this->expectExceptionMessage('Path contains files shared with you'); + $this->expectExceptionMessage('You cannot share a folder that contains other shares'); $path = $this->createMock(Folder::class); $path->method('getPath')->willReturn('path'); |