Skip to content

Commit

Permalink
fix disabling for ad created by manual way
Browse files Browse the repository at this point in the history
  • Loading branch information
strorch committed Dec 27, 2023
1 parent 0ab2cc5 commit b2d1036
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion src/Components/SmartAdComponent.php
Original file line number Diff line number Diff line change
Expand Up @@ -31,7 +31,7 @@ public function __construct($slug)
*/
public function render()
{
$smartAd = SmartAd::where('slug', $this->slug)->first();
$smartAd = SmartAd::where('slug', $this->slug)->where('enabled', true)->first();
return view('smart-ads::components.smart-ad-component', compact('smartAd'));
}
}

0 comments on commit b2d1036

Please sign in to comment.