Removed 'is'.
This commit is contained in:
parent
2d6f9d0f1b
commit
b49868e9c7
4 changed files with 5 additions and 5 deletions
|
@ -51,7 +51,7 @@ class AuthInfo {
|
|||
get => $this->sessionInfo?->id;
|
||||
}
|
||||
|
||||
public bool $isImpersonating {
|
||||
public bool $impersonating {
|
||||
get => $this->realUserInfo !== null;
|
||||
}
|
||||
|
||||
|
|
|
@ -45,7 +45,7 @@ class MessagesRoutes implements RouteHandler, UrlSource {
|
|||
return 401;
|
||||
|
||||
// do not allow access to PMs when impersonating in production mode
|
||||
if(!MSZ_DEBUG && $this->authInfo->isImpersonating)
|
||||
if(!MSZ_DEBUG && $this->authInfo->impersonating)
|
||||
return 403;
|
||||
|
||||
$globalPerms = $this->authInfo->getPerms('global');
|
||||
|
|
|
@ -215,7 +215,7 @@ final class OAuth2WebRoutes implements RouteHandler {
|
|||
'scope' => $scope,
|
||||
];
|
||||
|
||||
if($this->authInfo->isImpersonating)
|
||||
if($this->authInfo->impersonating)
|
||||
$result['user']['guise'] = [
|
||||
'name' => $this->authInfo->realUserInfo->name,
|
||||
'colour' => (string)$this->usersCtx->getUserColour($this->authInfo->realUserInfo),
|
||||
|
@ -403,7 +403,7 @@ final class OAuth2WebRoutes implements RouteHandler {
|
|||
],
|
||||
];
|
||||
|
||||
if($this->authInfo->isImpersonating)
|
||||
if($this->authInfo->impersonating)
|
||||
$result['user']['guise'] = [
|
||||
'name' => $this->authInfo->realUserInfo->name,
|
||||
'colour' => (string)$this->usersCtx->getUserColour($this->authInfo->realUserInfo),
|
||||
|
|
|
@ -1,7 +1,7 @@
|
|||
{% from 'macros.twig' import avatar %}
|
||||
{% from '_layout/input.twig' import input_checkbox_raw %}
|
||||
|
||||
{% if globals.auth_info.isImpersonating %}
|
||||
{% if globals.auth_info.impersonating %}
|
||||
{% set real_user_info = globals.auth_info.realUserInfo %}
|
||||
<div class="impersonate">
|
||||
<div class="impersonate-content">
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue