diff --git a/src/Security/User.php b/src/Security/User.php index 26dc440c..7b6054c7 100644 --- a/src/Security/User.php +++ b/src/Security/User.php @@ -302,6 +302,18 @@ final public function getAuthorizatorIfExists(): ?IAuthorizator } + /** + * Clear identity cache. + * @return $this + */ + final public function refresh() + { + $this->identity = false; + $this->authenticated = null; + return $this; + } + + /** @deprecated */ final public function hasAuthorizator(): bool {