@@ 21-34 (lines=14) @@ | ||
18 | /** @var UserManager */ |
|
19 | private $userManager; |
|
20 | ||
21 | public function __construct(/* UserManager */ $userManager) |
|
22 | { |
|
23 | parent::__construct(); |
|
24 | ||
25 | if (!$userManager instanceof UserManager && !$userManager instanceof FOSUserManager) { |
|
26 | throw new InvalidArgumentException(sprintf('The "$userManager" argument must be of type "%s" or type "%s"', UserManager::class, FOSUserManager::class)); |
|
27 | } |
|
28 | if ($userManager instanceof FOSUserManager) { |
|
29 | // NEXT_MAJOR set the usermanaged typehint to the kunstmaan usermanager. |
|
30 | @trigger_error(sprintf('Passing the usermanager from FOSUserBundle as the first argument of "%s" is deprecated since KunstmaanAdminBundle 5.8 and will be removed in KunstmaanAdminBundle 6.0. Use the new Kunstmaan Usermanager %s.', __METHOD__, UserManager::class), E_USER_DEPRECATED); |
|
31 | } |
|
32 | ||
33 | $this->userManager = $userManager; |
|
34 | } |
|
35 | ||
36 | protected function configure() |
|
37 | { |
@@ 23-33 (lines=11) @@ | ||
20 | /** |
|
21 | * @param UserManager $userManager |
|
22 | */ |
|
23 | public function __construct(/* UserManager */ $userManager) |
|
24 | { |
|
25 | if (!$userManager instanceof UserManager && !$userManager instanceof FOSUserManager) { |
|
26 | throw new \InvalidArgumentException(sprintf('The "$userManager" argument must be of type "%s" or type "%s"', UserManager::class, FOSUserManager::class)); |
|
27 | } |
|
28 | if ($userManager instanceof FOSUserManager) { |
|
29 | // NEXT_MAJOR set the usermanaged typehint to the kunstmaan usermanager. |
|
30 | @trigger_error(sprintf('Passing the usermanager from FOSUserBundle as the first argument of "%s" is deprecated since KunstmaanAdminBundle 5.8 and will be removed in KunstmaanAdminBundle 6.0. Use the "%s" class instead.', __METHOD__, UserManager::class), E_USER_DEPRECATED); |
|
31 | } |
|
32 | $this->userManager = $userManager; |
|
33 | } |
|
34 | ||
35 | /** |
|
36 | * @param FilterUserResponseEvent $event |
@@ 21-34 (lines=14) @@ | ||
18 | /** @var FOSUserManager|UserManager */ |
|
19 | protected $userManager; |
|
20 | ||
21 | public function __construct(/* UserManager */ $userManager) |
|
22 | { |
|
23 | parent::__construct(); |
|
24 | ||
25 | if (!$userManager instanceof UserManager && !$userManager instanceof FOSUserManager) { |
|
26 | throw new InvalidArgumentException(sprintf('The "$userManager" argument must be of type "%s" or type "%s"', UserManager::class, FOSUserManager::class)); |
|
27 | } |
|
28 | if ($userManager instanceof FOSUserManager) { |
|
29 | // NEXT_MAJOR set the usermanaged typehint to the kunstmaan usermanager. |
|
30 | @trigger_error(sprintf('Passing the usermanager from FOSUserBundle as the first argument of "%s" is deprecated since KunstmaanAdminBundle 5.8 and will be removed in KunstmaanAdminBundle 6.0. Use the new Kunstmaan Usermanager %s.', __METHOD__, UserManager::class), E_USER_DEPRECATED); |
|
31 | } |
|
32 | ||
33 | $this->userManager = $userManager; |
|
34 | } |
|
35 | ||
36 | protected function configure() |
|
37 | { |