registerLoginAfterRestore(); } private function registerLoginAfterRestore() { // Available in WordPress 4.6+ $action = 'login_header'; /** @see wp_version_check() */ if (file_exists(ABSPATH . WPINC . '/version.php')) { require ABSPATH . WPINC . '/version.php'; if (isset($GLOBALS['wp_version']) && version_compare($GLOBALS['wp_version'], '4.6', '<')) { // Available in WordPress >3.1 $action = 'login_footer'; } } add_action($action, [$this->container->make(LoginAfterRestore::class), 'showMessage'], 10, 0); // phpcs:ignore WPStaging.Security.FirstArgNotAString, WPStaging.Security.AuthorizationChecked } }