From b6da0b76afb5697685c35b8584631294cfc7b12f Mon Sep 17 00:00:00 2001 From: alecpl <alec@alec.pl> Date: Wed, 07 Dec 2011 05:41:15 -0500 Subject: [PATCH] - Remove deprecated global $IMAP variable usage (#1488148) --- index.php | 2 +- 1 files changed, 1 insertions(+), 1 deletions(-) diff --git a/index.php b/index.php index 550ee0c..6f761a4 100644 --- a/index.php +++ b/index.php @@ -129,7 +129,7 @@ $OUTPUT->redirect($redir); } else { - $error_code = is_object($IMAP) ? $IMAP->get_error_code() : -1; + $error_code = (isset($RCMAIL->imap) && is_object($RCMAIL->imap)) ? $RCMAIL->imap->get_error_code() : 1; $OUTPUT->show_message($error_code < -1 ? 'imaperror' : (!$auth['valid'] ? 'invalidrequest' : 'loginfailed'), 'warning'); $RCMAIL->plugins->exec_hook('login_failed', array( -- Gitblit v1.9.1