summaryrefslogtreecommitdiffstats
path: root/lib/public
diff options
context:
space:
mode:
authorVincent Petry <pvince81@owncloud.com>2015-06-16 16:47:10 +0200
committerVincent Petry <pvince81@owncloud.com>2015-06-16 16:47:10 +0200
commite5d34a273353e651c6609fffe9804a4755d3e80d (patch)
tree01f08b3a8152c56a85163cfaa1a869f359b296e6 /lib/public
parent829f6474ff4cd4e39647bcb5b68b5e5c0fb1b483 (diff)
parent0e3a3dd5d7fd9d57a099f3720af20b6f9a22d63f (diff)
downloadnextcloud-server-e5d34a273353e651c6609fffe9804a4755d3e80d.tar.gz
nextcloud-server-e5d34a273353e651c6609fffe9804a4755d3e80d.zip
Merge pull request #16892 from owncloud/lock-returnfullpath
Rethrow LockedException with full path
Diffstat (limited to 'lib/public')
-rw-r--r--lib/public/lock/lockedexception.php11
1 files changed, 8 insertions, 3 deletions
diff --git a/lib/public/lock/lockedexception.php b/lib/public/lock/lockedexception.php
index f8a0221f10b..d6cec4cc48a 100644
--- a/lib/public/lock/lockedexception.php
+++ b/lib/public/lock/lockedexception.php
@@ -28,7 +28,10 @@ namespace OCP\Lock;
* @since 8.1.0
*/
class LockedException extends \Exception {
+
/**
+ * Locked path
+ *
* @var string
*/
private $path;
@@ -36,11 +39,13 @@ class LockedException extends \Exception {
/**
* LockedException constructor.
*
- * @param string $path
+ * @param string $path locked path
+ * @param \Exception $previous previous exception for cascading
+ *
* @since 8.1.0
*/
- public function __construct($path) {
- parent::__construct($path . ' is locked');
+ public function __construct($path, \Exception $previous = null) {
+ parent::__construct('"' . $path . '" is locked', 0, $previous);
$this->path = $path;
}