@@ -23,6 +23,6 @@ |
||
23 | 23 | |
24 | 24 | namespace OCA\Files_Sharing; |
25 | 25 | |
26 | -interface ISharedStorage{ |
|
26 | +interface ISharedStorage { |
|
27 | 27 | |
28 | 28 | } |
@@ -37,7 +37,7 @@ discard block |
||
37 | 37 | |
38 | 38 | /** {@inheritDoc} */ |
39 | 39 | public function scan($path, $recursive = self::SCAN_RECURSIVE, $reuse = -1, $lock = true) { |
40 | - if(!$this->storage->remoteIsOwnCloud()) { |
|
40 | + if (!$this->storage->remoteIsOwnCloud()) { |
|
41 | 41 | return parent::scan($path, $recursive, $recursive, $lock); |
42 | 42 | } |
43 | 43 | |
@@ -88,8 +88,8 @@ discard block |
||
88 | 88 | } catch (\Exception $e) { |
89 | 89 | $this->storage->checkStorageAvailability(); |
90 | 90 | throw new \Exception( |
91 | - 'Error while scanning remote share: "' . |
|
92 | - $this->storage->getRemote() . '" ' . |
|
91 | + 'Error while scanning remote share: "'. |
|
92 | + $this->storage->getRemote().'" '. |
|
93 | 93 | $e->getMessage() |
94 | 94 | ); |
95 | 95 | } |
@@ -97,8 +97,8 @@ discard block |
||
97 | 97 | $this->addResult($data['data'], ''); |
98 | 98 | } else { |
99 | 99 | throw new \Exception( |
100 | - 'Error while scanning remote share: "' . |
|
101 | - $this->storage->getRemote() . '"' |
|
100 | + 'Error while scanning remote share: "'. |
|
101 | + $this->storage->getRemote().'"' |
|
102 | 102 | ); |
103 | 103 | } |
104 | 104 | } |
@@ -113,14 +113,14 @@ discard block |
||
113 | 113 | $children = []; |
114 | 114 | foreach ($data['children'] as $child) { |
115 | 115 | $children[$child['name']] = true; |
116 | - $this->addResult($child, ltrim($path . '/' . $child['name'], '/')); |
|
116 | + $this->addResult($child, ltrim($path.'/'.$child['name'], '/')); |
|
117 | 117 | } |
118 | 118 | |
119 | 119 | $existingCache = $this->cache->getFolderContentsById($id); |
120 | 120 | foreach ($existingCache as $existingChild) { |
121 | 121 | // if an existing child is not in the new data, remove it |
122 | 122 | if (!isset($children[$existingChild['name']])) { |
123 | - $this->cache->remove(ltrim($path . '/' . $existingChild['name'], '/')); |
|
123 | + $this->cache->remove(ltrim($path.'/'.$existingChild['name'], '/')); |
|
124 | 124 | } |
125 | 125 | } |
126 | 126 | } |
@@ -61,7 +61,7 @@ |
||
61 | 61 | $managerProvider = $this->managerProvider; |
62 | 62 | $manager = $managerProvider(); |
63 | 63 | $data['manager'] = $manager; |
64 | - $mountPoint = '/' . $user->getUID() . '/files/' . ltrim($data['mountpoint'], '/'); |
|
64 | + $mountPoint = '/'.$user->getUID().'/files/'.ltrim($data['mountpoint'], '/'); |
|
65 | 65 | $data['mountpoint'] = $mountPoint; |
66 | 66 | $data['cloudId'] = $this->cloudIdManager->getCloudId($data['owner'], $data['remote']); |
67 | 67 | $data['certificateManager'] = \OC::$server->getCertificateManager($user->getUID()); |
@@ -41,7 +41,7 @@ discard block |
||
41 | 41 | /** |
42 | 42 | * sets the correct interval for this timed job |
43 | 43 | */ |
44 | - public function __construct(){ |
|
44 | + public function __construct() { |
|
45 | 45 | $this->interval = $this->defaultIntervalMin * 60; |
46 | 46 | } |
47 | 47 | |
@@ -55,8 +55,8 @@ discard block |
||
55 | 55 | $logger = \OC::$server->getLogger(); |
56 | 56 | |
57 | 57 | $sql = |
58 | - 'DELETE FROM `*PREFIX*share` ' . |
|
59 | - 'WHERE `item_type` in (\'file\', \'folder\') ' . |
|
58 | + 'DELETE FROM `*PREFIX*share` '. |
|
59 | + 'WHERE `item_type` in (\'file\', \'folder\') '. |
|
60 | 60 | 'AND NOT EXISTS (SELECT `fileid` FROM `*PREFIX*filecache` WHERE `file_source` = `fileid`)'; |
61 | 61 | |
62 | 62 | $deletedEntries = $connection->executeUpdate($sql); |
@@ -96,7 +96,7 @@ discard block |
||
96 | 96 | */ |
97 | 97 | public function generateTarget($filePath, $shareWith, $exclude = null) { |
98 | 98 | $shareFolder = \OCA\Files_Sharing\Helper::getShareFolder(); |
99 | - $target = \OC\Files\Filesystem::normalizePath($shareFolder . '/' . basename($filePath)); |
|
99 | + $target = \OC\Files\Filesystem::normalizePath($shareFolder.'/'.basename($filePath)); |
|
100 | 100 | |
101 | 101 | // for group shares we return the target right away |
102 | 102 | if ($shareWith === false) { |
@@ -104,13 +104,13 @@ discard block |
||
104 | 104 | } |
105 | 105 | |
106 | 106 | \OC\Files\Filesystem::initMountPoints($shareWith); |
107 | - $view = new \OC\Files\View('/' . $shareWith . '/files'); |
|
107 | + $view = new \OC\Files\View('/'.$shareWith.'/files'); |
|
108 | 108 | |
109 | 109 | if (!$view->is_dir($shareFolder)) { |
110 | 110 | $dir = ''; |
111 | 111 | $subdirs = explode('/', $shareFolder); |
112 | 112 | foreach ($subdirs as $subdir) { |
113 | - $dir = $dir . '/' . $subdir; |
|
113 | + $dir = $dir.'/'.$subdir; |
|
114 | 114 | if (!$view->is_dir($dir)) { |
115 | 115 | $view->mkdir($dir); |
116 | 116 | } |
@@ -237,7 +237,7 @@ discard block |
||
237 | 237 | if ($share['item_type'] === 'folder' && $target !== '') { |
238 | 238 | // note: in case of ext storage mount points the path might be empty |
239 | 239 | // which would cause a leading slash to appear |
240 | - $share['path'] = ltrim($share['path'] . '/' . $target, '/'); |
|
240 | + $share['path'] = ltrim($share['path'].'/'.$target, '/'); |
|
241 | 241 | } |
242 | 242 | return self::resolveReshares($share); |
243 | 243 | } |
@@ -69,7 +69,7 @@ |
||
69 | 69 | */ |
70 | 70 | protected function run($argument) { |
71 | 71 | // Delete old tokens after 2 days |
72 | - if($this->timeFactory->getTime() - $this->config->getAppValue('core', 'updater.secret.created', $this->timeFactory->getTime()) >= 172800) { |
|
72 | + if ($this->timeFactory->getTime() - $this->config->getAppValue('core', 'updater.secret.created', $this->timeFactory->getTime()) >= 172800) { |
|
73 | 73 | $this->config->deleteSystemValue('updater.secret'); |
74 | 74 | } |
75 | 75 | } |
@@ -47,7 +47,7 @@ |
||
47 | 47 | $rows = $result->fetchAll(); |
48 | 48 | $result->closeCursor(); |
49 | 49 | |
50 | - return array_map(function ($row) { |
|
50 | + return array_map(function($row) { |
|
51 | 51 | return BackupCode::fromRow($row); |
52 | 52 | }, $rows); |
53 | 53 | } |
@@ -3,7 +3,7 @@ discard block |
||
3 | 3 | /** @var array $_ */ |
4 | 4 | |
5 | 5 | print_unescaped($l->t("Hey there,\n\nthe admin enabled server-side-encryption. Your files were encrypted using the password '%s'.\n\nPlease login to the web interface, go to the section 'basic encryption module' of your personal settings and update your encryption password by entering this password into the 'old log-in password' field and your current login-password.\n\n", array($_['password']))); |
6 | -if ( isset($_['expiration']) ) { |
|
6 | +if (isset($_['expiration'])) { |
|
7 | 7 | print_unescaped($l->t("The share will expire on %s.", array($_['expiration']))); |
8 | 8 | print_unescaped("\n\n"); |
9 | 9 | } |
@@ -12,5 +12,5 @@ discard block |
||
12 | 12 | ?> |
13 | 13 | |
14 | 14 | -- |
15 | -<?php p($theme->getName() . ' - ' . $theme->getSlogan()); ?> |
|
15 | +<?php p($theme->getName().' - '.$theme->getSlogan()); ?> |
|
16 | 16 | <?php print_unescaped("\n".$theme->getBaseUrl()); |
@@ -163,7 +163,7 @@ discard block |
||
163 | 163 | * @return bool |
164 | 164 | */ |
165 | 165 | public function userHasFiles($uid) { |
166 | - return $this->files->file_exists($uid . '/files'); |
|
166 | + return $this->files->file_exists($uid.'/files'); |
|
167 | 167 | } |
168 | 168 | |
169 | 169 | /** |
@@ -179,7 +179,7 @@ discard block |
||
179 | 179 | if (count($parts) > 1) { |
180 | 180 | $owner = $parts[1]; |
181 | 181 | if ($this->userManager->userExists($owner) === false) { |
182 | - throw new \BadMethodCallException('Unknown user: ' . |
|
182 | + throw new \BadMethodCallException('Unknown user: '. |
|
183 | 183 | 'method expects path to a user folder relative to the data folder'); |
184 | 184 | } |
185 | 185 |