@@ -73,7 +73,7 @@ discard block |
||
| 73 | 73 | * @param string $name |
| 74 | 74 | * @return Module|null |
| 75 | 75 | */ |
| 76 | - public function find(string $name):?Module |
|
| 76 | + public function find(string $name): ?Module |
|
| 77 | 77 | { |
| 78 | 78 | return $this->module->get($name); |
| 79 | 79 | } |
@@ -106,7 +106,7 @@ discard block |
||
| 106 | 106 | $this->modulePaths[] = Resource::getPathByRelativePath($path, $this->path); |
| 107 | 107 | } |
| 108 | 108 | } else { |
| 109 | - $this->modulePaths = [ Resource::getPathByRelativePath('modules', $this->path) ]; |
|
| 109 | + $this->modulePaths = [Resource::getPathByRelativePath('modules', $this->path)]; |
|
| 110 | 110 | } |
| 111 | 111 | } |
| 112 | 112 | |
@@ -244,7 +244,7 @@ discard block |
||
| 244 | 244 | $module = $default; |
| 245 | 245 | } |
| 246 | 246 | if ($module !== null && ($moduleObj = $this->find($module))) { |
| 247 | - return $moduleObj->getFullName() . ':' . $name; |
|
| 247 | + return $moduleObj->getFullName().':'.$name; |
|
| 248 | 248 | } |
| 249 | 249 | return $name; |
| 250 | 250 | } |
@@ -72,8 +72,8 @@ |
||
| 72 | 72 | 'context' => $this->context, |
| 73 | 73 | 'backtrace' => $throwable->getTrace(), |
| 74 | 74 | ]; |
| 75 | - $exceptionHash = md5($throwable->getFile() . $throwable->getLine() . $throwable->getCode()); |
|
| 76 | - $path = $dumpPath . '/' . microtime(true) . '.' . substr($exceptionHash, 0, 8) . '.json'; |
|
| 75 | + $exceptionHash = md5($throwable->getFile().$throwable->getLine().$throwable->getCode()); |
|
| 76 | + $path = $dumpPath.'/'.microtime(true).'.'.substr($exceptionHash, 0, 8).'.json'; |
|
| 77 | 77 | FileSystem::make($dumpPath); |
| 78 | 78 | FileSystem::put($path, json_encode( |
| 79 | 79 | new DebugObject($dumper), |
@@ -57,7 +57,7 @@ discard block |
||
| 57 | 57 | $group = $group ?? $request->getAttribute('group'); |
| 58 | 58 | $default = $default ?? $request->getAttribute('module'); |
| 59 | 59 | $url = $this->route->create($this->getRouteName($name, $default, $group), $parameter, $allowQuery); |
| 60 | - return $this->getUrlIndex($request) . ltrim($url, '/'); |
|
| 60 | + return $this->getUrlIndex($request).ltrim($url, '/'); |
|
| 61 | 61 | } |
| 62 | 62 | |
| 63 | 63 | /** |
@@ -89,7 +89,7 @@ discard block |
||
| 89 | 89 | public function getUriBase(Request $request, bool $beautify = true): string |
| 90 | 90 | { |
| 91 | 91 | $index = $beautify ? $this->getUrlIndex($request) : $request->getIndex(); |
| 92 | - return $request->getUriBase() . $index; |
|
| 92 | + return $request->getUriBase().$index; |
|
| 93 | 93 | } |
| 94 | 94 | |
| 95 | 95 | /** |
@@ -100,7 +100,7 @@ discard block |
||
| 100 | 100 | */ |
| 101 | 101 | protected function getRouteGroupPrefix(?string $group): string |
| 102 | 102 | { |
| 103 | - return $group === null || $group === 'default' ? '' : '@' . $group; |
|
| 103 | + return $group === null || $group === 'default' ? '' : '@'.$group; |
|
| 104 | 104 | } |
| 105 | 105 | |
| 106 | 106 | /** |
@@ -138,7 +138,7 @@ discard block |
||
| 138 | 138 | } |
| 139 | 139 | $prefixGroup = $this->getRouteGroupPrefix($group); |
| 140 | 140 | if ($module !== null && ($moduleObj = $this->find($module))) { |
| 141 | - return $moduleObj->getFullName() . $prefixGroup . ':' . $name; |
|
| 141 | + return $moduleObj->getFullName().$prefixGroup.':'.$name; |
|
| 142 | 142 | } |
| 143 | 143 | return $name; |
| 144 | 144 | } |