diff --git a/library/Icinga/Authentication/User/ExternalBackend.php b/library/Icinga/Authentication/User/ExternalBackend.php index 3baf1c8e0..c92bbd615 100644 --- a/library/Icinga/Authentication/User/ExternalBackend.php +++ b/library/Icinga/Authentication/User/ExternalBackend.php @@ -83,7 +83,7 @@ class ExternalBackend implements UserBackendInterface if ($this->stripUsernameRegexp) { $stripped = preg_replace($this->stripUsernameRegexp, '', $username); - if ($stripped !== false) { + if ($stripped !== null) { // TODO(el): PHP issues a warning when PHP cannot compile the regular expression. Should we log an // additional message in that case? $username = $stripped;