@@ -182,7 +182,7 @@ |
||
| 182 | 182 | return []; |
| 183 | 183 | } |
| 184 | 184 | |
| 185 | - return (array)require_once $userDependencies; |
|
| 185 | + return (array) require_once $userDependencies; |
|
| 186 | 186 | } |
| 187 | 187 | |
| 188 | 188 | /** |
@@ -98,7 +98,7 @@ |
||
| 98 | 98 | ]; |
| 99 | 99 | |
| 100 | 100 | if (isset($this->moduleOptions['cacheable'])) { |
| 101 | - $this->currentRoute['cache_settings']['shouldCache'] = (bool)$this->moduleOptions['cacheable']; |
|
| 101 | + $this->currentRoute['cache_settings']['shouldCache'] = (bool) $this->moduleOptions['cacheable']; |
|
| 102 | 102 | } |
| 103 | 103 | |
| 104 | 104 | if (is_callable($params[0])) { |
@@ -97,7 +97,7 @@ discard block |
||
| 97 | 97 | $this->matchedRoutes = $this->findMatches($uri); |
| 98 | 98 | |
| 99 | 99 | if (empty($this->matchedRoutes)) { |
| 100 | - stop(function () { |
|
| 100 | + stop(function() { |
|
| 101 | 101 | page_not_found(); |
| 102 | 102 | }); |
| 103 | 103 | } |
@@ -217,7 +217,7 @@ discard block |
||
| 217 | 217 | $routePattern = '(\/)?'; |
| 218 | 218 | $routeParams = []; |
| 219 | 219 | |
| 220 | - $lastIndex = (int)array_key_last($routeSegments); |
|
| 220 | + $lastIndex = (int) array_key_last($routeSegments); |
|
| 221 | 221 | |
| 222 | 222 | foreach ($routeSegments as $index => $segment) { |
| 223 | 223 | $segmentParam = $this->getSegmentParam($segment, $index, $lastIndex); |
@@ -65,7 +65,7 @@ discard block |
||
| 65 | 65 | { |
| 66 | 66 | $this->isEnabled = filter_var(config()->get('multilang'), FILTER_VALIDATE_BOOLEAN); |
| 67 | 67 | |
| 68 | - $langSegmentIndex = (int)config()->get(Lang::LANG_SEGMENT); |
|
| 68 | + $langSegmentIndex = (int) config()->get(Lang::LANG_SEGMENT); |
|
| 69 | 69 | |
| 70 | 70 | if (!empty(route_prefix()) && $langSegmentIndex == 1) { |
| 71 | 71 | $langSegmentIndex++; |
@@ -77,7 +77,7 @@ discard block |
||
| 77 | 77 | throw LangException::misconfiguredDefaultConfig(); |
| 78 | 78 | } |
| 79 | 79 | |
| 80 | - if (empty($lang) || !in_array($lang, (array)config()->get('langs'))) { |
|
| 80 | + if (empty($lang) || !in_array($lang, (array) config()->get('langs'))) { |
|
| 81 | 81 | $lang = config()->get('lang_default'); |
| 82 | 82 | } |
| 83 | 83 | |
@@ -85,7 +85,7 @@ discard block |
||
| 85 | 85 | if (config()->get('debug')) { |
| 86 | 86 | $this->mailer->SMTPDebug = SMTP::DEBUG_SERVER; |
| 87 | 87 | |
| 88 | - $this->mailer->Debugoutput = function ($message) { |
|
| 88 | + $this->mailer->Debugoutput = function($message) { |
|
| 89 | 89 | warning($message, ['tab' => Debugger::MAILS]); |
| 90 | 90 | }; |
| 91 | 91 | } |
@@ -187,7 +187,7 @@ discard block |
||
| 187 | 187 | */ |
| 188 | 188 | public function setAttachment(string $attachment): SmtpAdapter |
| 189 | 189 | { |
| 190 | - $this->attachments[] = $attachment;; |
|
| 190 | + $this->attachments[] = $attachment; ; |
|
| 191 | 191 | return $this; |
| 192 | 192 | } |
| 193 | 193 | |
@@ -98,7 +98,7 @@ |
||
| 98 | 98 | { |
| 99 | 99 | $this->client = new MultiCurl(); |
| 100 | 100 | |
| 101 | - $this->client->complete(function (Curl $instance) { |
|
| 101 | + $this->client->complete(function(Curl $instance) { |
|
| 102 | 102 | $this->handleResponse($instance); |
| 103 | 103 | }); |
| 104 | 104 | |
@@ -62,7 +62,7 @@ |
||
| 62 | 62 | */ |
| 63 | 63 | public function encrypt(string $plain): string |
| 64 | 64 | { |
| 65 | - if(!$this->publicKey) { |
|
| 65 | + if (!$this->publicKey) { |
|
| 66 | 66 | throw CryptorException::publicKeyNotProvided(); |
| 67 | 67 | } |
| 68 | 68 | |
@@ -29,11 +29,11 @@ |
||
| 29 | 29 | */ |
| 30 | 30 | public function get(string $field, ?string $value): ?User; |
| 31 | 31 | |
| 32 | - /** |
|
| 33 | - * Add |
|
| 34 | - * @param array $data |
|
| 35 | - * @return User |
|
| 36 | - */ |
|
| 32 | + /** |
|
| 33 | + * Add |
|
| 34 | + * @param array $data |
|
| 35 | + * @return User |
|
| 36 | + */ |
|
| 37 | 37 | public function add(array $data): User; |
| 38 | 38 | |
| 39 | 39 | /** |
@@ -273,8 +273,8 @@ |
||
| 273 | 273 | return false; |
| 274 | 274 | } |
| 275 | 275 | |
| 276 | - if(isset($message->error)) { |
|
| 277 | - $error = (array)$message->error; |
|
| 276 | + if (isset($message->error)) { |
|
| 277 | + $error = (array) $message->error; |
|
| 278 | 278 | |
| 279 | 279 | if (!isset($error['.tag']) && !in_array($error['.tag'], self::ACCESS_TOKEN_STATUS)) { |
| 280 | 280 | return false; |