Skip to content

Commit

Permalink
Check enable_clause for be an object.
Browse files Browse the repository at this point in the history
  • Loading branch information
Christian Hellmund committed Mar 26, 2021
1 parent 3bb3c60 commit aa38c50
Showing 1 changed file with 3 additions and 1 deletion.
4 changes: 3 additions & 1 deletion Classes/Services/OAuth2LoginService.php
Original file line number Diff line number Diff line change
Expand Up @@ -144,7 +144,9 @@ public function fetchUserRecord($username, $dbUserSetup = '')
->add(GeneralUtility::makeInstance(DeletedRestriction::class));
$constraints = array_filter([
QueryHelper::stripLogicalOperatorPrefix($dbUser['check_pid_clause']),
$dbUser['enable_clause'],
is_object($dbUser['enable_clause']) ?
$dbUser['enable_clause'] :
QueryHelper::stripLogicalOperatorPrefix($dbUser['enable_clause']),
$query->expr()->eq(
$dbUser['username_column'],
$query->createNamedParameter($username, \PDO::PARAM_STR)
Expand Down

0 comments on commit aa38c50

Please sign in to comment.