Passed
Push — master ( 7796f0...ca9076 )
by 世昌
01:52
created
nebula/src/application/module/Builder.php 1 patch
Spacing   +2 added lines, -2 removed lines patch added patch discarded remove patch
@@ -42,9 +42,9 @@
 block discarded – undo
42 42
             $extension !== 'module') {
43 43
             return null;
44 44
         }
45
-        $zip=new ZipArchive;
45
+        $zip = new ZipArchive;
46 46
         if ($zip->open($path, ZipArchive::CHECKCONS)) {
47
-            $unzipPath = $unpackPath.'/'. pathinfo($path, PATHINFO_FILENAME) .'-'.substr(md5_file($path), 0, 8);
47
+            $unzipPath = $unpackPath.'/'.pathinfo($path, PATHINFO_FILENAME).'-'.substr(md5_file($path), 0, 8);
48 48
             $zip->extractTo($unzipPath);
49 49
             $zip->close();
50 50
             return Config::resolve($unzipPath.'/module');
Please login to merge, or discard this patch.
nebula/src/application/module/Manager.php 1 patch
Spacing   +2 added lines, -2 removed lines patch added patch discarded remove patch
@@ -117,7 +117,7 @@  discard block
 block discarded – undo
117 117
     public function registerModule()
118 118
     {
119 119
         $scan = $this->getApp()->getConfig('app.module.scan-path', []);
120
-        $cache = $this->getDataPath() .'/module-cache';
120
+        $cache = $this->getDataPath().'/module-cache';
121 121
         FileSystem::makes($cache);
122 122
         foreach (Builder::scan($scan, $cache) as $module) {
123 123
             $this->finder->add($module->getName(), $module->getVersion());
@@ -133,7 +133,7 @@  discard block
 block discarded – undo
133 133
      * @param string $name
134 134
      * @return Module|null
135 135
      */     
136
-    public function find(string $name):?Module {
136
+    public function find(string $name): ?Module {
137 137
         $fullName = $this->finder->getFullName($name);
138 138
         return $this->module[$fullName] ?? null;
139 139
     }
Please login to merge, or discard this patch.