Closed dhaarbrink closed 11 years ago
If you look at the top of the file, you'll see:
use ZfcUser\Entity\UserInterface as User;
This means that your new custom class simply needs to implement this interface and it will then work.
Doh! I'll go and get more coffee :)
Sorry to bother you!
I have defined a custom user entity class, but I get an exception:
exception 'ZfcUser\Exception\DomainException' with message '$user is not an instance of User'
It is triggered here: ZfcUser\View\Helper\ZfcUserDisplayName:28
The check on line 27 of that file should read from the config and check if there is a custom class defined, AND satisfies the requirement that it should at least have a couple of methods defined: getDisplayName(), getUserName() and getEmail().
For now I don't see a way around this and resorted to manually disabling the check, which means I can't deploy to production at the moment (since I'm using composer).