04 10 2023 snapshot

This commit is contained in:
Anatoliy Poloz
2023-10-04 17:57:09 +03:00
parent 1e546fa48e
commit 09a00744a0
441 changed files with 41582 additions and 254079 deletions

View File

@@ -35,7 +35,15 @@ class Recipe extends Model implements Viewable
public function author()
{
return $this->hasOneThrough(User::class, RecipeAuthor::class, 'recipe_id', 'id', 'id', 'user_id');
return $this
->hasOneThrough(User::class, RecipeAuthor::class, 'recipe_id', 'id', 'id', 'user_id')
->withDefault(
[
'name' => 'Guest Author',
'id' => 0,
'profile_photo_url' => 'https://dev2.eatvio.com/storage/profile-photos/mW87tqy9P8O31Dauyvg8f7GowMNMsgt9J6u47T7S.jpg'
]
);
}
public function comments()