File tree Expand file tree Collapse file tree 1 file changed +7
-5
lines changed Expand file tree Collapse file tree 1 file changed +7
-5
lines changed Original file line number Diff line number Diff line change @@ -20,13 +20,15 @@ public function handle(): int
20
20
{
21
21
intro ('Clearing build and dist directories... ' );
22
22
23
+ $ filesystem = new Filesystem ;
24
+
23
25
// Removing and recreating the native serve resource path
24
26
$ nativeServeResourcePath = realpath (__DIR__ .'/../../resources/js/resources/app/ ' );
25
- $ this -> line ( ' Clearing: ' . $ nativeServeResourcePath );
26
-
27
- $ filesystem = new Filesystem ;
28
- $ filesystem ->remove ($ nativeServeResourcePath );
29
- $ filesystem -> mkdir ( $ nativeServeResourcePath );
27
+ if ( $ filesystem -> exists ( $ nativeServeResourcePath )) {
28
+ $ this -> line ( ' Clearing: ' . $ nativeServeResourcePath );
29
+ $ filesystem -> remove ( $ nativeServeResourcePath ) ;
30
+ $ filesystem ->mkdir ($ nativeServeResourcePath );
31
+ }
30
32
31
33
// Removing the bundling directories
32
34
$ bundlingPath = base_path ('build/ ' );
You can’t perform that action at this time.
0 commit comments