Completed
Pull Request — master (#768)
by Antoine
05:26
created
src/Composer/ScriptHandler.php 2 patches
Indentation   +14 added lines, -14 removed lines patch added patch discarded remove patch
@@ -18,27 +18,27 @@
 block discarded – undo
18 18
 class ScriptHandler
19 19
 {
20 20
 
21
-  protected static $destination = '/src/Bridge/Symfony/Bundle/Resources/public/swagger-ui/dist';
22
-  protected static $source = '/vendor/swagger-api/swagger-ui/dist';
23
-
24
-  /**
25
-   * Copy swagger ui to the correct directory
26
-   *
27
-   * @parm Event $event
28
-   */
29
-  public static function installSwaggerUi(Event $event) {
21
+    protected static $destination = '/src/Bridge/Symfony/Bundle/Resources/public/swagger-ui/dist';
22
+    protected static $source = '/vendor/swagger-api/swagger-ui/dist';
23
+
24
+    /**
25
+     * Copy swagger ui to the correct directory
26
+     *
27
+     * @parm Event $event
28
+     */
29
+    public static function installSwaggerUi(Event $event) {
30 30
     $fs = new Filesystem();
31 31
     $finder = new Finder();
32 32
     $cwd = getcwd();
33 33
 
34 34
     foreach($finder->in($cwd.self::$source) as $file) {
35
-      $destination = $cwd.self::$destination.'/'.$file->getRelativePathname();
36
-      if ($file->isDir()) {
35
+        $destination = $cwd.self::$destination.'/'.$file->getRelativePathname();
36
+        if ($file->isDir()) {
37 37
         $fs->mkdir($destination);
38 38
         continue;
39
-      }
39
+        }
40 40
 
41
-      $fs->copy($file->getRealPath(), $destination, true);
41
+        $fs->copy($file->getRealPath(), $destination, true);
42
+    }
42 43
     }
43
-  }
44 44
 }
Please login to merge, or discard this patch.
Spacing   +1 added lines, -1 removed lines patch added patch discarded remove patch
@@ -31,7 +31,7 @@
 block discarded – undo
31 31
     $finder = new Finder();
32 32
     $cwd = getcwd();
33 33
 
34
-    foreach($finder->in($cwd.self::$source) as $file) {
34
+    foreach ($finder->in($cwd.self::$source) as $file) {
35 35
       $destination = $cwd.self::$destination.'/'.$file->getRelativePathname();
36 36
       if ($file->isDir()) {
37 37
         $fs->mkdir($destination);
Please login to merge, or discard this patch.