Skip to content
Snippets Groups Projects

Feature upgrade to9 lts

Merged Kevin Ditscheid requested to merge feature_UpgradeTo9LTS into master
Compare and Show latest version
16 files
+ 258
206
Compare changes
  • Side-by-side
  • Inline
Files
16
@@ -92,10 +92,23 @@ class AuthService extends AbstractService {
* @throws \InvalidArgumentException
*/
public function getUser() {
$userRecord = NULL;
if (!$this->parentObject) {
// The whole logic in this method is obsolete if fe_user is not accessible
return $userRecord;
return NULL;
}
$userRecord = NULL;
$userUid = (int) GeneralUtility::_GP('viewasuser');
if ($userUid > 0) {
return $this->baseService->getUserByUid($userUid);
}
$loginHash = trim((string) GeneralUtility::_GP('loginhash'));
if ($loginHash !== '') {
$userUid = $this->baseService->getUserUidByLoginHash(
$loginHash, $this->authenticationInformation['db_user']['checkPidList']
);
return $this->parentObject->getRawUserByUid($userUid);
}
$this->parentObject->fetchUserSession();
@@ -124,13 +137,6 @@ class AuthService extends AbstractService {
$userRecord = $this->parentObject->getRawUserByUid($userUid);
}
}
} elseif ($loginHash = GeneralUtility::_GP('loginhash')) {
$userUid = $this->baseService->getUserUidByLoginHash(
$loginHash, $this->authenticationInformation['db_user']['checkPidList']
);
$userRecord = $this->parentObject->getRawUserByUid($userUid);
} elseif ($userUid = GeneralUtility::_GP('viewasuser')) {
$userRecord = $this->baseService->getUserByUid($userUid);
}
return $userRecord;
Loading