@@ -56,7 +56,7 @@ discard block |
||
56 | 56 | $keys = array_filter(array_keys($aliases), function($k) { |
57 | 57 | return $k[0] === '_'; |
58 | 58 | }); |
59 | - foreach($keys as $key) { |
|
59 | + foreach ($keys as $key) { |
|
60 | 60 | unset($aliases[$key]); |
61 | 61 | } |
62 | 62 | |
@@ -64,7 +64,7 @@ discard block |
||
64 | 64 | $dir = new \DirectoryIterator(\OC::$SERVERROOT.'/core/img/filetypes'); |
65 | 65 | |
66 | 66 | $files = []; |
67 | - foreach($dir as $fileInfo) { |
|
67 | + foreach ($dir as $fileInfo) { |
|
68 | 68 | if ($fileInfo->isFile()) { |
69 | 69 | $file = preg_replace('/.[^.]*$/', '', $fileInfo->getFilename()); |
70 | 70 | $files[] = $file; |
@@ -78,14 +78,14 @@ discard block |
||
78 | 78 | // Fetch all themes! |
79 | 79 | $themes = []; |
80 | 80 | $dirs = new \DirectoryIterator(\OC::$SERVERROOT.'/themes/'); |
81 | - foreach($dirs as $dir) { |
|
81 | + foreach ($dirs as $dir) { |
|
82 | 82 | //Valid theme dir |
83 | 83 | if ($dir->isFile() || $dir->isDot()) { |
84 | 84 | continue; |
85 | 85 | } |
86 | 86 | |
87 | 87 | $theme = $dir->getFilename(); |
88 | - $themeDir = $dir->getPath() . '/' . $theme . '/core/img/filetypes/'; |
|
88 | + $themeDir = $dir->getPath().'/'.$theme.'/core/img/filetypes/'; |
|
89 | 89 | // Check if this theme has its own filetype icons |
90 | 90 | if (!file_exists($themeDir)) { |
91 | 91 | continue; |
@@ -116,9 +116,9 @@ discard block |
||
116 | 116 | * To regenerate this file run ./occ maintenance:mimetype:update-js |
117 | 117 | */ |
118 | 118 | OC.MimeTypeList={ |
119 | - aliases: ' . json_encode($aliases, JSON_PRETTY_PRINT | JSON_UNESCAPED_SLASHES) . ', |
|
120 | - files: ' . json_encode($files, JSON_PRETTY_PRINT) . ', |
|
121 | - themes: ' . json_encode($themes, JSON_PRETTY_PRINT) . ' |
|
119 | + aliases: ' . json_encode($aliases, JSON_PRETTY_PRINT | JSON_UNESCAPED_SLASHES).', |
|
120 | + files: ' . json_encode($files, JSON_PRETTY_PRINT).', |
|
121 | + themes: ' . json_encode($themes, JSON_PRETTY_PRINT).' |
|
122 | 122 | }; |
123 | 123 | '; |
124 | 124 |
@@ -54,7 +54,7 @@ |
||
54 | 54 | try { |
55 | 55 | $client = $this->clientService->newClient(); |
56 | 56 | $response = $client->get( |
57 | - $lookupServerUrl . '/users?search=' . urlencode($search), |
|
57 | + $lookupServerUrl.'/users?search='.urlencode($search), |
|
58 | 58 | [ |
59 | 59 | 'timeout' => 10, |
60 | 60 | 'connect_timeout' => 3, |
@@ -75,7 +75,7 @@ discard block |
||
75 | 75 | $this->doFind($resource); |
76 | 76 | } catch (ResourceNotFoundException $e) { |
77 | 77 | $resourceApp = substr($resource, 0, strpos($resource, '/')); |
78 | - $this->logger->debug('Could not find resource file "' . $e->getResourcePath() . '"', ['app' => $resourceApp]); |
|
78 | + $this->logger->debug('Could not find resource file "'.$e->getResourcePath().'"', ['app' => $resourceApp]); |
|
79 | 79 | } |
80 | 80 | } |
81 | 81 | if (!empty($this->theme)) { |
@@ -84,7 +84,7 @@ discard block |
||
84 | 84 | $this->doFindTheme($resource); |
85 | 85 | } catch (ResourceNotFoundException $e) { |
86 | 86 | $resourceApp = substr($resource, 0, strpos($resource, '/')); |
87 | - $this->logger->debug('Could not find resource file in theme "' . $e->getResourcePath() . '"', ['app' => $resourceApp]); |
|
87 | + $this->logger->debug('Could not find resource file in theme "'.$e->getResourcePath().'"', ['app' => $resourceApp]); |
|
88 | 88 | } |
89 | 89 | } |
90 | 90 | } |
@@ -185,7 +185,7 @@ discard block |
||
185 | 185 | } |
186 | 186 | $this->resources[] = array($root, $webRoot, $file); |
187 | 187 | |
188 | - if ($throw && !is_file($root . '/' . $file)) { |
|
188 | + if ($throw && !is_file($root.'/'.$file)) { |
|
189 | 189 | throw new ResourceNotFoundException($file, $webRoot); |
190 | 190 | } |
191 | 191 | } |
@@ -46,15 +46,15 @@ |
||
46 | 46 | const CREATE_GROUP = 0x00000001; |
47 | 47 | const DELETE_GROUP = 0x00000010; |
48 | 48 | const ADD_TO_GROUP = 0x00000100; |
49 | - const REMOVE_FROM_GOUP = 0x00001000; // oops |
|
50 | - const REMOVE_FROM_GROUP = 0x00001000; |
|
49 | + const REMOVE_FROM_GOUP = 0x00001000; // oops |
|
50 | + const REMOVE_FROM_GROUP = 0x00001000; |
|
51 | 51 | //OBSOLETE const GET_DISPLAYNAME = 0x00010000; |
52 | - const COUNT_USERS = 0x00100000; |
|
53 | - const GROUP_DETAILS = 0x01000000; |
|
52 | + const COUNT_USERS = 0x00100000; |
|
53 | + const GROUP_DETAILS = 0x01000000; |
|
54 | 54 | /** |
55 | 55 | * @since 13.0.0 |
56 | 56 | */ |
57 | - const IS_ADMIN = 0x10000000; |
|
57 | + const IS_ADMIN = 0x10000000; |
|
58 | 58 | |
59 | 59 | /** |
60 | 60 | * Check if backend implements actions |
@@ -71,18 +71,18 @@ |
||
71 | 71 | $errorMessage = $this->getLastError(); |
72 | 72 | if ($errorMessage) { |
73 | 73 | throw new \OC\DatabaseSetupException($this->trans->t('Oracle connection could not be established'), |
74 | - $errorMessage . ' Check environment: ORACLE_HOME=' . getenv('ORACLE_HOME') |
|
75 | - . ' ORACLE_SID=' . getenv('ORACLE_SID') |
|
76 | - . ' LD_LIBRARY_PATH=' . getenv('LD_LIBRARY_PATH') |
|
77 | - . ' NLS_LANG=' . getenv('NLS_LANG') |
|
78 | - . ' tnsnames.ora is ' . (is_readable(getenv('ORACLE_HOME') . '/network/admin/tnsnames.ora') ? '' : 'not ') . 'readable'); |
|
74 | + $errorMessage.' Check environment: ORACLE_HOME='.getenv('ORACLE_HOME') |
|
75 | + . ' ORACLE_SID='.getenv('ORACLE_SID') |
|
76 | + . ' LD_LIBRARY_PATH='.getenv('LD_LIBRARY_PATH') |
|
77 | + . ' NLS_LANG='.getenv('NLS_LANG') |
|
78 | + . ' tnsnames.ora is '.(is_readable(getenv('ORACLE_HOME').'/network/admin/tnsnames.ora') ? '' : 'not ').'readable'); |
|
79 | 79 | } |
80 | 80 | throw new \OC\DatabaseSetupException($this->trans->t('Oracle username and/or password not valid'), |
81 | - 'Check environment: ORACLE_HOME=' . getenv('ORACLE_HOME') |
|
82 | - . ' ORACLE_SID=' . getenv('ORACLE_SID') |
|
83 | - . ' LD_LIBRARY_PATH=' . getenv('LD_LIBRARY_PATH') |
|
84 | - . ' NLS_LANG=' . getenv('NLS_LANG') |
|
85 | - . ' tnsnames.ora is ' . (is_readable(getenv('ORACLE_HOME') . '/network/admin/tnsnames.ora') ? '' : 'not ') . 'readable'); |
|
81 | + 'Check environment: ORACLE_HOME='.getenv('ORACLE_HOME') |
|
82 | + . ' ORACLE_SID='.getenv('ORACLE_SID') |
|
83 | + . ' LD_LIBRARY_PATH='.getenv('LD_LIBRARY_PATH') |
|
84 | + . ' NLS_LANG='.getenv('NLS_LANG') |
|
85 | + . ' tnsnames.ora is '.(is_readable(getenv('ORACLE_HOME').'/network/admin/tnsnames.ora') ? '' : 'not ').'readable'); |
|
86 | 86 | } |
87 | 87 | |
88 | 88 | $this->config->setValues([ |
@@ -88,7 +88,7 @@ |
||
88 | 88 | protected function shouldRun() { |
89 | 89 | $schema = $this->db->createSchema(); |
90 | 90 | |
91 | - $tableName = $this->config->getSystemValue('dbtableprefix', 'oc_') . 'accounts'; |
|
91 | + $tableName = $this->config->getSystemValue('dbtableprefix', 'oc_').'accounts'; |
|
92 | 92 | if (!$schema->hasTable($tableName)) { |
93 | 93 | return false; |
94 | 94 | } |
@@ -79,7 +79,7 @@ discard block |
||
79 | 79 | $searchResult->markExactIdMatch($resultType); |
80 | 80 | } |
81 | 81 | $result['exact'][] = [ |
82 | - 'label' => $contact['FN'] . " ($cloudId)", |
|
82 | + 'label' => $contact['FN']." ($cloudId)", |
|
83 | 83 | 'value' => [ |
84 | 84 | 'shareType' => Share::SHARE_TYPE_REMOTE, |
85 | 85 | 'shareWith' => $cloudId, |
@@ -88,7 +88,7 @@ discard block |
||
88 | 88 | ]; |
89 | 89 | } else { |
90 | 90 | $result['wide'][] = [ |
91 | - 'label' => $contact['FN'] . " ($cloudId)", |
|
91 | + 'label' => $contact['FN']." ($cloudId)", |
|
92 | 92 | 'value' => [ |
93 | 93 | 'shareType' => Share::SHARE_TYPE_REMOTE, |
94 | 94 | 'shareWith' => $cloudId, |
@@ -47,7 +47,7 @@ discard block |
||
47 | 47 | $searchResult = $this->c->resolve(SearchResult::class); |
48 | 48 | |
49 | 49 | foreach ($shareTypes as $type) { |
50 | - if(!isset($this->pluginList[$type])) { |
|
50 | + if (!isset($this->pluginList[$type])) { |
|
51 | 51 | continue; |
52 | 52 | } |
53 | 53 | foreach ($this->pluginList[$type] as $plugin) { |
@@ -70,18 +70,18 @@ discard block |
||
70 | 70 | // that the exact same email address and federated cloud id exists |
71 | 71 | $emailType = new SearchResultType('emails'); |
72 | 72 | $remoteType = new SearchResultType('remotes'); |
73 | - if($searchResult->hasExactIdMatch($emailType) && !$searchResult->hasExactIdMatch($remoteType)) { |
|
73 | + if ($searchResult->hasExactIdMatch($emailType) && !$searchResult->hasExactIdMatch($remoteType)) { |
|
74 | 74 | $searchResult->unsetResult($remoteType); |
75 | 75 | } elseif (!$searchResult->hasExactIdMatch($emailType) && $searchResult->hasExactIdMatch($remoteType)) { |
76 | 76 | $searchResult->unsetResult($emailType); |
77 | 77 | } |
78 | 78 | |
79 | - return [$searchResult->asArray(), (bool)$hasMoreResults]; |
|
79 | + return [$searchResult->asArray(), (bool) $hasMoreResults]; |
|
80 | 80 | } |
81 | 81 | |
82 | 82 | public function registerPlugin(array $pluginInfo) { |
83 | - $shareType = constant(Share::class . '::' . $pluginInfo['shareType']); |
|
84 | - if($shareType === null) { |
|
83 | + $shareType = constant(Share::class.'::'.$pluginInfo['shareType']); |
|
84 | + if ($shareType === null) { |
|
85 | 85 | throw new \InvalidArgumentException('Provided ShareType is invalid'); |
86 | 86 | } |
87 | 87 | $this->pluginList[$shareType][] = $pluginInfo['class']; |
@@ -126,7 +126,7 @@ discard block |
||
126 | 126 | $template->setSubject($this->l->t('Password for %1$s changed on %2$s', [$user->getDisplayName(), $instanceUrl])); |
127 | 127 | $template->addHeader(); |
128 | 128 | $template->addHeading($this->l->t('Password changed for %s', [$user->getDisplayName()]), false); |
129 | - $template->addBodyText($text . ' ' . $this->l->t('If you did not request this, please contact an administrator.')); |
|
129 | + $template->addBodyText($text.' '.$this->l->t('If you did not request this, please contact an administrator.')); |
|
130 | 130 | $template->addFooter(); |
131 | 131 | |
132 | 132 | |
@@ -196,7 +196,7 @@ discard block |
||
196 | 196 | $template->setSubject($this->l->t('Email address for %1$s changed on %2$s', [$user->getDisplayName(), $instanceUrl])); |
197 | 197 | $template->addHeader(); |
198 | 198 | $template->addHeading($this->l->t('Email address changed for %s', [$user->getDisplayName()]), false); |
199 | - $template->addBodyText($text . ' ' . $this->l->t('If you did not request this, please contact an administrator.')); |
|
199 | + $template->addBodyText($text.' '.$this->l->t('If you did not request this, please contact an administrator.')); |
|
200 | 200 | if ($user->getEMailAddress()) { |
201 | 201 | $template->addBodyText($this->l->t('The new email address is %s', [$user->getEMailAddress()])); |
202 | 202 | } |