@@ -73,8 +73,8 @@ |
||
73 | 73 | */ |
74 | 74 | public function render(array $option = []) |
75 | 75 | { |
76 | - return '<div class="embed-responsive embed-responsive-16by9">' . |
|
77 | - '<iframe class="embed-responsive-item" src="' . $this->url() . '"></iframe>' . |
|
76 | + return '<div class="embed-responsive embed-responsive-16by9">'. |
|
77 | + '<iframe class="embed-responsive-item" src="'.$this->url().'"></iframe>'. |
|
78 | 78 | '</div>'; |
79 | 79 | } |
80 | 80 |
@@ -67,8 +67,8 @@ |
||
67 | 67 | */ |
68 | 68 | public function render(array $option = []) |
69 | 69 | { |
70 | - return '<audio controls src="' . $this->url() . '">' . |
|
71 | - 'Your user agent does not support the HTML5 Audio element.' . |
|
70 | + return '<audio controls src="'.$this->url().'">'. |
|
71 | + 'Your user agent does not support the HTML5 Audio element.'. |
|
72 | 72 | '</audio>'; |
73 | 73 | } |
74 | 74 |
@@ -94,7 +94,7 @@ |
||
94 | 94 | $path ?: '', |
95 | 95 | implode('_', [ |
96 | 96 | $command->getName(), |
97 | - $command->getDimension()->getWidth() . 'x' . $command->getDimension()->getHeight(), |
|
97 | + $command->getDimension()->getWidth().'x'.$command->getDimension()->getHeight(), |
|
98 | 98 | hash('sha1', $content), |
99 | 99 | ]), |
100 | 100 | $disk, |
@@ -70,17 +70,17 @@ |
||
70 | 70 | */ |
71 | 71 | function bytes($bytes, $unit = null, $dec = 2) |
72 | 72 | { |
73 | - $size = ['B', 'kB', 'MB', 'GB', 'TB', 'PB', 'EB', 'ZB', 'YB']; |
|
73 | + $size = ['B', 'kB', 'MB', 'GB', 'TB', 'PB', 'EB', 'ZB', 'YB']; |
|
74 | 74 | if (in_array($unit, $size)) { |
75 | 75 | $factor = array_search($unit, $size); |
76 | 76 | } else { |
77 | - $factor = (int)((strlen($bytes) - 1) / 3); |
|
77 | + $factor = (int) ((strlen($bytes) - 1) / 3); |
|
78 | 78 | } |
79 | 79 | $dec = $factor == 0 ? 0 : $dec; |
80 | 80 | if ($factor >= count($size)) { |
81 | 81 | $factor = count($size) - 1; |
82 | 82 | } |
83 | 83 | |
84 | - return sprintf("%.{$dec}f", $bytes / pow(1024, $factor)) . $size[$factor]; |
|
84 | + return sprintf("%.{$dec}f", $bytes / pow(1024, $factor)).$size[$factor]; |
|
85 | 85 | } |
86 | 86 | } |
@@ -92,7 +92,7 @@ |
||
92 | 92 | |
93 | 93 | // prepend ":" to each key |
94 | 94 | $keys = array_map( |
95 | - function ($key) { |
|
95 | + function($key) { |
|
96 | 96 | return ':'.$key; |
97 | 97 | }, |
98 | 98 | array_keys($this->args) |
@@ -137,7 +137,7 @@ |
||
137 | 137 | { |
138 | 138 | $config = [ |
139 | 139 | 'instanceId' => $instanceId, |
140 | - 'group' => 'documents_' . $instanceId, |
|
140 | + 'group' => 'documents_'.$instanceId, |
|
141 | 141 | ]; |
142 | 142 | |
143 | 143 | $config = array_merge($config, $params); |
@@ -339,7 +339,7 @@ discard block |
||
339 | 339 | { |
340 | 340 | $timestamp = time(); |
341 | 341 | if ($this->parentId == null || $this->parentId == '') { |
342 | - $this->setAttribute('head', $timestamp . '-' . $this->id); |
|
342 | + $this->setAttribute('head', $timestamp.'-'.$this->id); |
|
343 | 343 | } elseif ($this->parentId !== $this->id) { |
344 | 344 | $parent = static::find($this->parentId); |
345 | 345 | if ($parent === null) { |
@@ -348,7 +348,7 @@ discard block |
||
348 | 348 | $this->setAttribute('reply', $this->getReplyChar($parent)); |
349 | 349 | $this->setAttribute('head', $parent->head); |
350 | 350 | } |
351 | - $this->setAttribute('listOrder', $this->head . (isset($this->reply) ? $this->reply : '')); |
|
351 | + $this->setAttribute('listOrder', $this->head.(isset($this->reply) ? $this->reply : '')); |
|
352 | 352 | } |
353 | 353 | |
354 | 354 | /** |
@@ -381,7 +381,7 @@ discard block |
||
381 | 381 | protected function getReplyChar(Document $parent) |
382 | 382 | { |
383 | 383 | $lastReply = self::where('head', $parent->head) |
384 | - ->where('reply', 'like', $parent->reply . str_repeat('_', self::$replyCharLen)) |
|
384 | + ->where('reply', 'like', $parent->reply.str_repeat('_', self::$replyCharLen)) |
|
385 | 385 | ->max('reply'); |
386 | 386 | |
387 | 387 | $lastChar = null; |
@@ -389,7 +389,7 @@ discard block |
||
389 | 389 | $lastChar = substr($lastReply, -1 * self::getReplyCharLen()); |
390 | 390 | } |
391 | 391 | |
392 | - return $parent->reply . $this->makeReplyChar($lastChar); |
|
392 | + return $parent->reply.$this->makeReplyChar($lastChar); |
|
393 | 393 | } |
394 | 394 | |
395 | 395 | /** |
@@ -408,15 +408,15 @@ discard block |
||
408 | 408 | return str_repeat($std[0], self::getReplyCharLen()); |
409 | 409 | } |
410 | 410 | |
411 | - if ($prevChars[strlen($prevChars)-1] == end($std)) { |
|
411 | + if ($prevChars[strlen($prevChars) - 1] == end($std)) { |
|
412 | 412 | if (strlen($prevChars) < 2) { |
413 | 413 | throw new ReplyLimitationException; |
414 | 414 | } |
415 | 415 | reset($std); |
416 | - $new = $this->makeReplyChar(substr($prevChars, 0, strlen($prevChars)-1)) . current($std); |
|
416 | + $new = $this->makeReplyChar(substr($prevChars, 0, strlen($prevChars) - 1)).current($std); |
|
417 | 417 | } else { |
418 | - $key = array_search($prevChars[strlen($prevChars)-1], $std); |
|
419 | - $new = substr($prevChars, 0, strlen($prevChars)-1) . $std[$key + 1]; |
|
418 | + $key = array_search($prevChars[strlen($prevChars) - 1], $std); |
|
419 | + $new = substr($prevChars, 0, strlen($prevChars) - 1).$std[$key + 1]; |
|
420 | 420 | } |
421 | 421 | |
422 | 422 | return $new; |
@@ -148,7 +148,7 @@ discard block |
||
148 | 148 | // sort |
149 | 149 | $activated = array_merge(array_flip($keys), $activated); |
150 | 150 | |
151 | - return array_filter($activated, function ($val) { |
|
151 | + return array_filter($activated, function($val) { |
|
152 | 152 | return !empty($val); |
153 | 153 | }); |
154 | 154 | } |
@@ -174,7 +174,7 @@ discard block |
||
174 | 174 | */ |
175 | 175 | protected function getConfigKey($id, $instanceId) |
176 | 176 | { |
177 | - return 'toggleMenu@' . $id . ($instanceId !== null ? '.' . $instanceId : ''); |
|
177 | + return 'toggleMenu@'.$id.($instanceId !== null ? '.'.$instanceId : ''); |
|
178 | 178 | } |
179 | 179 | |
180 | 180 | /** |
@@ -196,6 +196,6 @@ discard block |
||
196 | 196 | */ |
197 | 197 | private function getTypeKey($id) |
198 | 198 | { |
199 | - return $id . PluginRegister::KEY_DELIMITER . 'toggleMenu'; |
|
199 | + return $id.PluginRegister::KEY_DELIMITER.'toggleMenu'; |
|
200 | 200 | } |
201 | 201 | } |
@@ -39,7 +39,7 @@ |
||
39 | 39 | if (stripos($moduleId, 'module/') !== false) { |
40 | 40 | return $moduleId; |
41 | 41 | } else { |
42 | - return 'module/' . $moduleId; |
|
42 | + return 'module/'.$moduleId; |
|
43 | 43 | } |
44 | 44 | } |
45 | 45 | } |