Skip to content

Commit bd9f603

Browse files
Fix mark content as skipped when it doesnt exist
1 parent 6818e6a commit bd9f603

File tree

1 file changed

+4
-0
lines changed

1 file changed

+4
-0
lines changed

src/Pipes/Content.php

Lines changed: 4 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -30,6 +30,10 @@ public function backup(Zipper $zip, Closure $next)
3030
{
3131
$contentPath = config('backup.content_path');
3232

33+
if (!File::exists($contentPath)) {
34+
return $this->skip(reason: 'Content directory didn\'t exist, is it configured correctly?', next: $next, zip: $zip);
35+
}
36+
3337
$zip->addDirectory($contentPath, static::getKey());
3438

3539
return $next($zip);

0 commit comments

Comments
 (0)