Replies: 1 comment
-
if you are trying to run job or event and you're construct model attach
|
Beta Was this translation helpful? Give feedback.
0 replies
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Uh oh!
There was an error while loading. Please reload this page.
Uh oh!
There was an error while loading. Please reload this page.
-
Hello,
I'm using spatie/laravel-sluggable on Laravel ^9 but after new update I got error Serialization of 'Closure' is not allowed when I want using extra scope for using multi tenancy via below code:
/**
* Get the options for generating the slug.
*/
public function getSlugOptions(): SlugOptions
{
return SlugOptions::create()
->generateSlugsFrom('name')
->saveSlugsTo('slug')
->extraScope(fn (Builder $builder) => $builder->where('tenant_id', app('currentTenant')->id));
}
Beta Was this translation helpful? Give feedback.
All reactions