X-Git-Url: https://git.mxchange.org/?p=mailer.git;a=blobdiff_plain;f=inc%2Fmodules%2Fadmin%2Fadmin-inc.php;h=7817289f93aff946bc218780962e996755c29d6a;hp=76d9c6666c1b3979292b222b13ea4f75786613b0;hb=e45e218c4f629ec63f0788cab231bfc88b3fa46e;hpb=c544e11e6c117f1a1757bbc98b19e9675dc9b3cb
diff --git a/inc/modules/admin/admin-inc.php b/inc/modules/admin/admin-inc.php
index 76d9c6666c..7817289f93 100644
--- a/inc/modules/admin/admin-inc.php
+++ b/inc/modules/admin/admin-inc.php
@@ -52,7 +52,7 @@ function addAdminAccount ($adminLogin, $passHash, $adminEmail) {
array($adminLogin), __FUNCTION__, __LINE__);
// Is the entry there?
- if (SQL_NUMROWS($result) == '0') {
+ if (SQL_HASZERONUMS($result)) {
// Ok, let's create the admin login
SQL_QUERY_ESC("INSERT INTO `{?_MYSQL_PREFIX?}_admins` (`login`, `password`, `email`) VALUES ('%s', '%s', '%s')",
array(
@@ -253,7 +253,7 @@ ORDER BY
$OUT .= '
';
// @TODO Rewrite this to $content = SQL_FETCHARRAY()
while (list($menu, $title, $descr) = SQL_FETCHROW($result_main)) {
- if ((isExtensionActive('admins')) && (getExtensionVersion('admins') > '0.2.0')) {
+ if (isExtensionInstalledAndActive('admins', '0.2.0')) {
$ACL = adminsCheckAdminAcl($menu, '');
} else {
// @TODO ACL is 'allow'... hmmm
@@ -325,7 +325,7 @@ ORDER BY
// @TODO Rewrite this to $content = SQL_FETCHARRAY()
while (list($what_sub, $title_what, $desc_what) = SQL_FETCHROW($result_what)) {
// Check for access level
- if ((isExtensionActive('admins')) && (getExtensionVersion('admins') > '0.2.0')) {
+ if (isExtensionInstalledAndNewer('admins', '0.2.0')) {
$ACL = adminsCheckAdminAcl('', $what_sub);
} else {
// @TODO ACL is 'allow'... hmmm
@@ -394,7 +394,7 @@ ORDER BY
}
// Create member selection box
-function addMemberSelectionBox ($def=0, $add_all=false, $return=false, $none=false, $field='userid') {
+function addMemberSelectionBox ($def = 0, $add_all = false, $return = false, $none = false, $field = 'userid') {
// Output selection form with all confirmed user accounts listed
$result = SQL_QUERY("SELECT `userid`, `surname`, `family` FROM `{?_MYSQL_PREFIX?}_user_data` ORDER BY `userid` ASC", __FUNCTION__, __LINE__);
@@ -406,7 +406,7 @@ function addMemberSelectionBox ($def=0, $add_all=false, $return=false, $none=fal
elseif ($none === true) $OUT = ' ';
while ($content = SQL_FETCHARRAY($result)) {
- $OUT .= '