remove unused role ROLE_CUSTOMER (#712)

This commit is contained in:
Kevin Papst
2019-04-19 18:42:25 +02:00
committed by GitHub
parent 48f3ad842d
commit 32b36f42f0
15 changed files with 1 additions and 48 deletions

View File

@@ -153,10 +153,6 @@ class UserFixtures extends Fixture
protected function getUserDefinition()
{
return [
[
'Clara Haynes', 'CFO', 'clara_customer', 'clara_customer@example.com', User::ROLE_CUSTOMER,
'https://www.gravatar.com/avatar/00000000000000000000000000000000?d=monsterid&f=y', true
],
[
'John Doe', 'Developer', self::USERNAME_USER, 'john_user@example.com', User::ROLE_USER,
self::DEFAULT_AVATAR, true

View File

@@ -30,7 +30,6 @@ use Symfony\Component\Validator\Constraints as Assert;
*/
class User extends BaseUser implements UserInterface
{
public const ROLE_CUSTOMER = 'ROLE_CUSTOMER';
public const ROLE_USER = 'ROLE_USER';
public const ROLE_TEAMLEAD = 'ROLE_TEAMLEAD';
public const ROLE_ADMIN = 'ROLE_ADMIN';

View File

@@ -14,16 +14,12 @@ use Symfony\Component\Validator\Constraint;
use Symfony\Component\Validator\ConstraintValidator;
use Symfony\Component\Validator\Exception\UnexpectedTypeException;
/**
* Class RoleValidator
*/
class RoleValidator extends ConstraintValidator
{
/**
* @var string[]
*/
protected $allowedRoles = [
User::ROLE_CUSTOMER,
User::ROLE_USER,
User::ROLE_TEAMLEAD,
User::ROLE_ADMIN,