@@ -53,9 +53,9 @@ discard block |
||
53 | 53 | /** |
54 | 54 | * listen to write event. |
55 | 55 | */ |
56 | - public static function write_hook( $params ) { |
|
56 | + public static function write_hook($params) { |
|
57 | 57 | $path = $params[\OC\Files\Filesystem::signal_param_path]; |
58 | - if($path !== '') { |
|
58 | + if ($path !== '') { |
|
59 | 59 | Storage::store($path); |
60 | 60 | } |
61 | 61 | } |
@@ -70,7 +70,7 @@ discard block |
||
70 | 70 | */ |
71 | 71 | public static function remove_hook($params) { |
72 | 72 | $path = $params[\OC\Files\Filesystem::signal_param_path]; |
73 | - if($path !== '') { |
|
73 | + if ($path !== '') { |
|
74 | 74 | Storage::delete($path); |
75 | 75 | } |
76 | 76 | } |
@@ -81,7 +81,7 @@ discard block |
||
81 | 81 | */ |
82 | 82 | public static function pre_remove_hook($params) { |
83 | 83 | $path = $params[\OC\Files\Filesystem::signal_param_path]; |
84 | - if($path !== '') { |
|
84 | + if ($path !== '') { |
|
85 | 85 | Storage::markDeletedFile($path); |
86 | 86 | } |
87 | 87 | } |
@@ -96,7 +96,7 @@ discard block |
||
96 | 96 | public static function rename_hook($params) { |
97 | 97 | $oldpath = $params['oldpath']; |
98 | 98 | $newpath = $params['newpath']; |
99 | - if($oldpath !== '' && $newpath !== '') { |
|
99 | + if ($oldpath !== '' && $newpath !== '') { |
|
100 | 100 | Storage::renameOrCopy($oldpath, $newpath, 'rename'); |
101 | 101 | } |
102 | 102 | } |
@@ -111,7 +111,7 @@ discard block |
||
111 | 111 | public static function copy_hook($params) { |
112 | 112 | $oldpath = $params['oldpath']; |
113 | 113 | $newpath = $params['newpath']; |
114 | - if($oldpath !== '' && $newpath !== '') { |
|
114 | + if ($oldpath !== '' && $newpath !== '') { |
|
115 | 115 | Storage::renameOrCopy($oldpath, $newpath, 'copy'); |
116 | 116 | } |
117 | 117 | } |
@@ -127,7 +127,7 @@ discard block |
||
127 | 127 | public static function pre_renameOrCopy_hook($params) { |
128 | 128 | // if we rename a movable mount point, then the versions don't have |
129 | 129 | // to be renamed |
130 | - $absOldPath = \OC\Files\Filesystem::normalizePath('/' . \OCP\User::getUser() . '/files' . $params['oldpath']); |
|
130 | + $absOldPath = \OC\Files\Filesystem::normalizePath('/'.\OCP\User::getUser().'/files'.$params['oldpath']); |
|
131 | 131 | $manager = \OC\Files\Filesystem::getMountManager(); |
132 | 132 | $mount = $manager->find($absOldPath); |
133 | 133 | $internalPath = $mount->getInternalPath($absOldPath); |
@@ -135,7 +135,7 @@ discard block |
||
135 | 135 | return; |
136 | 136 | } |
137 | 137 | |
138 | - $view = new \OC\Files\View(\OCP\User::getUser() . '/files'); |
|
138 | + $view = new \OC\Files\View(\OCP\User::getUser().'/files'); |
|
139 | 139 | if ($view->file_exists($params['newpath'])) { |
140 | 140 | Storage::store($params['newpath']); |
141 | 141 | } else { |