diff --git a/interface/web/login/password_reset.php b/interface/web/login/password_reset.php
index dbb545d6a6e56021acedf8069aab74a04ad2e3f1..c0d454cd326fce1f1e6ae5d72b55bcf5675cfbb2 100644
--- a/interface/web/login/password_reset.php
+++ b/interface/web/login/password_reset.php
@@ -85,6 +85,7 @@ if(isset($_POST['username']) && $_POST['username'] != '' && $_POST['email'] != '
 			if(isset($_SERVER['SERVER_PORT']) && $_SERVER['SERVER_PORT'] != '443') $server_domain .= ':' . $_SERVER['SERVER_PORT'];
 			
 			$app->uses('getconf,ispcmail');
+			$server_config_array = $app->getconf->get_global_config();
 			$mail_config = $server_config_array['mail'];
 			if($mail_config['smtp_enabled'] == 'y') {
 				$mail_config['use_smtp'] = true;