Open phillipsnick opened 10 years ago
As username can't be null a quick fix has been added to the user entity
public function setEmail($email)
{
if (is_null($this->getUsername())) {
$this->setUsername(uniqid());
}
return parent::setEmail($email);
}
Also investigate dropping from sonata table See about overriding vendor/sonata-project/user-bundle/Admin/Entity/UserAdmin.php
Potential hack found here https://github.com/FriendsOfSymfony/FOSUserBundle/issues/555#issuecomment-59510228
Some details on using the event listeners here https://github.com/FriendsOfSymfony/FOSUserBundle/blob/master/Resources/doc/controller_events.md