Interface "App\Filament\AvatarProviders\Contracts\AvatarProvider" not found
I have created a file BoringAvatarsProvider.php in app/Filament/AvatarProviders/
and put there this:
and added this to panel:
->defaultAvatarProvider(BoringAvatarsProvider::class);
And I am getting the error message:
In the editor the part : implements Contracts\AvatarProvider
has Contracts\AvatarProvider
with a yellow background and it says on hover:
undefined namespace Contracts.
Do I need to create some other files to make this work?
I have followed the docs here https://filamentphp.com/docs/3.x/panels/users#using-a-different-avatar-provider and there is nothing else to do, no mention about creating additional files, just this one BoringAvatarsProvider.php
and putting the ->defaultAvatarProvider(BoringAvatarsProvider::class); in the panel chain.3 Replies
OK, apparently there should be an additional import. I just have to figure out what exactly.
Solution
You saw my PR, right? So this is solved?
Will check on github now.
Great the
use Filament\AvatarProviders\Contracts;
as you added there solved it. Now I see some buiscit or whatnot smiling at me instead of initials π . Thanks.