]> git.mxchange.org Git - mailer.git/blobdiff - inc/libs/admins_functions.php
Conflict solved, more templates added, TODOs.txt updated:
[mailer.git] / inc / libs / admins_functions.php
index e0424383fbfd88db20236932c865e1ce6a130017..de6dcd93b84a493006601988e259b8862a883335 100644 (file)
@@ -420,7 +420,7 @@ function adminsListAdminAccounts() {
 }
 
 // Sends out mail to all administrators
-// IMPORTANT: Please use SEND_ADMIN_NOTIFCATION() for now!
+// IMPORTANT: Please use sendAdminNotification() instead of calling this function directly
 function sendAdminsEmails ($subj, $template, $content, $userid) {
        // Trim template name
        $template = trim($template);
@@ -463,7 +463,7 @@ function sendAdminsEmails ($subj, $template, $content, $userid) {
                                        $userid
                                ));
                        }
-               } elseif ($adminId == '0') {
+               } elseif (($adminId == '0') || (empty($adminId))) {
                        // Select all email adresses
                        $result = SQL_QUERY("SELECT `email` FROM `{?_MYSQL_PREFIX?}_admins` ORDER BY `id` ASC",
                                __FUNCTION__, __LINE__);
@@ -648,8 +648,8 @@ function FILTER_ADD_EXTRA_SQL_DATA ($add = '') {
 // Reset the login failures
 function FILTER_RESET_ADMINS_LOGIN_FAILURES ($data) {
        // Store it in session
-       setSession('mxchange_admin_failures'    , getAdminLoginFailures($data['login']));
-       setSession('mxchange_admin_last_failure', getAdminLastFailure($data['login']));
+       setSession('mailer_admin_failures'    , getAdminLoginFailures($data['login']));
+       setSession('mailer_admin_last_failure', getAdminLastFailure($data['login']));
 
        // Prepare update data
        $postData['login'][getCurrentAdminId()]          = $data['login'];