Elgg\PersistentLoginService::handleDbException PHP Method

handleDbException() protected method

Swallow a schema not upgraded exception, otherwise rethrow it
protected handleDbException ( DatabaseException $exception, string $default = null ) : mixed
$exception DatabaseException The exception to handle
$default string The value to return if the table doesn't exist yet
return mixed
    protected function handleDbException(\DatabaseException $exception, $default = null)
    {
        if (false !== strpos($exception->getMessage(), "users_remember_me_cookies' doesn't exist")) {
            // schema has not been updated so we swallow this exception
            return $default;
        } else {
            throw $exception;
        }
    }