File tree Expand file tree Collapse file tree 1 file changed +9
-7
lines changed
Expand file tree Collapse file tree 1 file changed +9
-7
lines changed Original file line number Diff line number Diff line change @@ -19,15 +19,17 @@ public function __construct(Task $task, $started)
1919
2020 $ time_elapsed_secs = microtime (true ) - $ started ;
2121
22- $ output = file_get_contents (storage_path ($ task ->getMutexName ()));
22+ if (file_exists (storage_path ($ task ->getMutexName ()))) {
23+ $ output = file_get_contents (storage_path ($ task ->getMutexName ()));
2324
24- $ task ->results ()->create ([
25- 'duration ' => $ time_elapsed_secs * 1000 ,
26- 'result ' => $ output ,
27- ]);
25+ $ task ->results ()->create ([
26+ 'duration ' => $ time_elapsed_secs * 1000 ,
27+ 'result ' => $ output ,
28+ ]);
2829
29- unlink (storage_path ($ task ->getMutexName ()));
30+ unlink (storage_path ($ task ->getMutexName ()));
3031
31- $ task ->notify (new TaskCompleted ($ output ));
32+ $ task ->notify (new TaskCompleted ($ output ));
33+ }
3234 }
3335}
You can’t perform that action at this time.
0 commit comments