MDL-45814 login: don't prompt guest user to change password

This commit is contained in:
Dan Poltawski
2015-11-03 14:49:43 +00:00
parent c12979c7df
commit 56272bb56d
+1 -1
View File
@@ -199,7 +199,7 @@ if ($frm and isset($frm->username)) { // Login WITH
/// check if user password has expired
/// Currently supported only for ldap-authentication module
$userauth = get_auth_plugin($USER->auth);
if (!empty($userauth->config->expiration) and $userauth->config->expiration == 1) {
if (!isguestuser() and !empty($userauth->config->expiration) and $userauth->config->expiration == 1) {
if ($userauth->can_change_password()) {
$passwordchangeurl = $userauth->change_password_url();
if (!$passwordchangeurl) {