Skip to content

Commit

Permalink
Add deprecation
Browse files Browse the repository at this point in the history
  • Loading branch information
bytehead committed Nov 12, 2021
1 parent 2b2297f commit e28b713
Showing 1 changed file with 5 additions and 0 deletions.
5 changes: 5 additions & 0 deletions core-bundle/src/Security/User/ContaoUserProvider.php
Original file line number Diff line number Diff line change
Expand Up @@ -49,8 +49,13 @@ public function __construct(ContaoFramework $framework, SessionInterface $sessio
$this->logger = $logger;
}

/**
* @deprecated Deprecated since Contao 4.13, to be removed in Contao 5.0.
*/
public function loadUserByUsername($username): User
{
trigger_deprecation('contao/core-bundle', '4.13', 'Using "ContaoUserProvider::loadUserByUsername()" has been deprecated and will no longer work in Contao 5.0. Use ContaoUserProvider::loadUserByIdentifier() instead.');

return $this->loadUserByIdentifier($username);
}

Expand Down

0 comments on commit e28b713

Please sign in to comment.