Skip to content

Commit

Permalink
fix(block-patterns): Use content instead of a view if it exists (Fixes
Browse files Browse the repository at this point in the history
 #52) (#53)
  • Loading branch information
Log1x committed Jul 24, 2023
1 parent 3bc3a1d commit 0db825a
Showing 1 changed file with 1 addition and 5 deletions.
6 changes: 1 addition & 5 deletions src/Modules/BlockPatternModule.php
Original file line number Diff line number Diff line change
Expand Up @@ -42,11 +42,7 @@ public function handle()

$view = 'block-patterns.' . Str::after($key, '/');

if (! view()->exists($view)) {
return;
}

if (! $value->has('content')) {
if (view()->exists($view)) {
$value['content'] = view($view)->render();
}

Expand Down

0 comments on commit 0db825a

Please sign in to comment.