@@ -1,17 +1,17 @@ |
||
1 | 1 | <?php |
2 | 2 | // @codeCoverageIgnoreStart |
3 | -if(!isset($_)) {//standalone page is not supported anymore - redirect to / |
|
3 | +if (!isset($_)) {//standalone page is not supported anymore - redirect to / |
|
4 | 4 | require_once '../../lib/base.php'; |
5 | 5 | |
6 | 6 | $urlGenerator = \OC::$server->getURLGenerator(); |
7 | - header('Location: ' . $urlGenerator->getAbsoluteURL('/')); |
|
7 | + header('Location: '.$urlGenerator->getAbsoluteURL('/')); |
|
8 | 8 | exit; |
9 | 9 | } |
10 | 10 | // @codeCoverageIgnoreEnd |
11 | 11 | ?> |
12 | 12 | <ul> |
13 | 13 | <li class='error'> |
14 | - <?php p($l->t( 'Access forbidden' )); ?><br> |
|
15 | - <p class='hint'><?php if(isset($_['file'])) p($_['file'])?></p> |
|
14 | + <?php p($l->t('Access forbidden')); ?><br> |
|
15 | + <p class='hint'><?php if (isset($_['file'])) p($_['file'])?></p> |
|
16 | 16 | </li> |
17 | 17 | </ul> |
@@ -3,11 +3,11 @@ |
||
3 | 3 | /** @var $l \OCP\IL10N */ |
4 | 4 | /** @var $theme OCP\Defaults */ |
5 | 5 | // @codeCoverageIgnoreStart |
6 | -if(!isset($_)) {//standalone page is not supported anymore - redirect to / |
|
6 | +if (!isset($_)) {//standalone page is not supported anymore - redirect to / |
|
7 | 7 | require_once '../../lib/base.php'; |
8 | 8 | |
9 | 9 | $urlGenerator = \OC::$server->getURLGenerator(); |
10 | - header('Location: ' . $urlGenerator->getAbsoluteURL('/')); |
|
10 | + header('Location: '.$urlGenerator->getAbsoluteURL('/')); |
|
11 | 11 | exit; |
12 | 12 | } |
13 | 13 | // @codeCoverageIgnoreEnd |
@@ -41,20 +41,20 @@ |
||
41 | 41 | |
42 | 42 | $tmpDir = \OC::$server->getTempManager()->getTempBaseDir(); |
43 | 43 | |
44 | - $defaultParameters = ' -env:UserInstallation=file://' . escapeshellarg($tmpDir . '/owncloud-' . \OC_Util::getInstanceId() . '/') . ' --headless --nologo --nofirststartwizard --invisible --norestore --convert-to pdf --outdir '; |
|
44 | + $defaultParameters = ' -env:UserInstallation=file://'.escapeshellarg($tmpDir.'/owncloud-'.\OC_Util::getInstanceId().'/').' --headless --nologo --nofirststartwizard --invisible --norestore --convert-to pdf --outdir '; |
|
45 | 45 | $clParameters = \OC::$server->getConfig()->getSystemValue('preview_office_cl_parameters', $defaultParameters); |
46 | 46 | |
47 | - $exec = $this->cmd . $clParameters . escapeshellarg($tmpDir) . ' ' . escapeshellarg($absPath); |
|
47 | + $exec = $this->cmd.$clParameters.escapeshellarg($tmpDir).' '.escapeshellarg($absPath); |
|
48 | 48 | |
49 | 49 | shell_exec($exec); |
50 | 50 | |
51 | 51 | //create imagick object from pdf |
52 | 52 | $pdfPreview = null; |
53 | 53 | try { |
54 | - list($dirname, , , $filename) = array_values(pathinfo($absPath)); |
|
55 | - $pdfPreview = $dirname . '/' . $filename . '.pdf'; |
|
54 | + list($dirname,,, $filename) = array_values(pathinfo($absPath)); |
|
55 | + $pdfPreview = $dirname.'/'.$filename.'.pdf'; |
|
56 | 56 | |
57 | - $pdf = new \imagick($pdfPreview . '[0]'); |
|
57 | + $pdf = new \imagick($pdfPreview.'[0]'); |
|
58 | 58 | $pdf->setImageFormat('jpg'); |
59 | 59 | } catch (\Exception $e) { |
60 | 60 | unlink($absPath); |
@@ -25,6 +25,6 @@ |
||
25 | 25 | |
26 | 26 | class PgSqlFunctionBuilder extends FunctionBuilder { |
27 | 27 | public function concat($x, $y) { |
28 | - return new QueryFunction('(' . $this->helper->quoteColumnName($x) . ' || ' . $this->helper->quoteColumnName($y) . ')'); |
|
28 | + return new QueryFunction('('.$this->helper->quoteColumnName($x).' || '.$this->helper->quoteColumnName($y).')'); |
|
29 | 29 | } |
30 | 30 | } |
@@ -25,6 +25,6 @@ |
||
25 | 25 | |
26 | 26 | class SqliteFunctionBuilder extends FunctionBuilder { |
27 | 27 | public function concat($x, $y) { |
28 | - return new QueryFunction('(' . $this->helper->quoteColumnName($x) . ' || ' . $this->helper->quoteColumnName($y) . ')'); |
|
28 | + return new QueryFunction('('.$this->helper->quoteColumnName($x).' || '.$this->helper->quoteColumnName($y).')'); |
|
29 | 29 | } |
30 | 30 | } |
@@ -61,7 +61,7 @@ discard block |
||
61 | 61 | } |
62 | 62 | |
63 | 63 | protected function execute(InputInterface $input, OutputInterface $output) { |
64 | - if ($input->getOption('shipped') === 'true' || $input->getOption('shipped') === 'false'){ |
|
64 | + if ($input->getOption('shipped') === 'true' || $input->getOption('shipped') === 'false') { |
|
65 | 65 | $shippedFilter = $input->getOption('shipped') === 'true'; |
66 | 66 | } else { |
67 | 67 | $shippedFilter = null; |
@@ -73,7 +73,7 @@ discard block |
||
73 | 73 | |
74 | 74 | //sort enabled apps above disabled apps |
75 | 75 | foreach ($apps as $app) { |
76 | - if ($shippedFilter !== null && $this->manager->isShipped($app) !== $shippedFilter){ |
|
76 | + if ($shippedFilter !== null && $this->manager->isShipped($app) !== $shippedFilter) { |
|
77 | 77 | continue; |
78 | 78 | } |
79 | 79 | if ($this->manager->isInstalled($app)) { |
@@ -87,10 +87,10 @@ discard block |
||
87 | 87 | $result = $query->execute(); |
88 | 88 | |
89 | 89 | if ($result) { |
90 | - return (int)$this->connection->lastInsertId('*PREFIX*'.$this->dbTable); |
|
90 | + return (int) $this->connection->lastInsertId('*PREFIX*'.$this->dbTable); |
|
91 | 91 | } |
92 | 92 | |
93 | - $message = 'Internal failure, Could not add trusted server: ' . $url; |
|
93 | + $message = 'Internal failure, Could not add trusted server: '.$url; |
|
94 | 94 | $message_t = $this->IL10N->t('Could not add server'); |
95 | 95 | throw new HintException($message, $message_t); |
96 | 96 | } |
@@ -124,7 +124,7 @@ discard block |
||
124 | 124 | $result = $query->execute()->fetchAll(); |
125 | 125 | |
126 | 126 | if (empty($result)) { |
127 | - throw new \Exception('No Server found with ID: ' . $id); |
|
127 | + throw new \Exception('No Server found with ID: '.$id); |
|
128 | 128 | } |
129 | 129 | |
130 | 130 | return $result[0]; |
@@ -201,7 +201,7 @@ discard block |
||
201 | 201 | $statement->closeCursor(); |
202 | 202 | |
203 | 203 | if (!isset($result['token'])) { |
204 | - throw new \Exception('No token found for: ' . $url); |
|
204 | + throw new \Exception('No token found for: '.$url); |
|
205 | 205 | } |
206 | 206 | |
207 | 207 | return $result['token']; |
@@ -278,7 +278,7 @@ discard block |
||
278 | 278 | $statement = $query->execute(); |
279 | 279 | $result = $statement->fetch(); |
280 | 280 | $statement->closeCursor(); |
281 | - return (int)$result['status']; |
|
281 | + return (int) $result['status']; |
|
282 | 282 | } |
283 | 283 | |
284 | 284 | /** |
@@ -129,7 +129,7 @@ discard block |
||
129 | 129 | $mailer = $this->getInstance(); |
130 | 130 | |
131 | 131 | // Enable logger if debug mode is enabled |
132 | - if($debugMode) { |
|
132 | + if ($debugMode) { |
|
133 | 133 | $mailLogger = new \Swift_Plugins_Loggers_ArrayLogger(); |
134 | 134 | $mailer->registerPlugin(new \Swift_Plugins_LoggerPlugin($mailLogger)); |
135 | 135 | } |
@@ -139,7 +139,7 @@ discard block |
||
139 | 139 | // Debugging logging |
140 | 140 | $logMessage = sprintf('Sent mail to "%s" with subject "%s"', print_r($message->getTo(), true), $message->getSubject()); |
141 | 141 | $this->logger->debug($logMessage, ['app' => 'core']); |
142 | - if($debugMode && isset($mailLogger)) { |
|
142 | + if ($debugMode && isset($mailLogger)) { |
|
143 | 143 | $this->logger->debug($mailLogger->dump(), ['app' => 'core']); |
144 | 144 | } |
145 | 145 | |
@@ -170,7 +170,7 @@ discard block |
||
170 | 170 | } |
171 | 171 | |
172 | 172 | list($name, $domain) = explode('@', $email, 2); |
173 | - $domain = idn_to_ascii($domain, 0,INTL_IDNA_VARIANT_UTS46); |
|
173 | + $domain = idn_to_ascii($domain, 0, INTL_IDNA_VARIANT_UTS46); |
|
174 | 174 | return $name.'@'.$domain; |
175 | 175 | } |
176 | 176 | |
@@ -240,7 +240,7 @@ discard block |
||
240 | 240 | break; |
241 | 241 | } |
242 | 242 | |
243 | - return \Swift_SendmailTransport::newInstance($binaryPath . ' -bs'); |
|
243 | + return \Swift_SendmailTransport::newInstance($binaryPath.' -bs'); |
|
244 | 244 | } |
245 | 245 | |
246 | 246 | /** |
@@ -150,7 +150,7 @@ |
||
150 | 150 | public function actionInclude($file) { |
151 | 151 | $function = function($param) use ($file) { |
152 | 152 | unset($param["_route"]); |
153 | - $_GET=array_merge($_GET, $param); |
|
153 | + $_GET = array_merge($_GET, $param); |
|
154 | 154 | unset($param); |
155 | 155 | require_once "$file"; |
156 | 156 | } ; |