From: Roland Häder Date: Fri, 19 Dec 2008 19:33:27 +0000 (+0000) Subject: Final fixes for SQL execution X-Git-Url: https://git.mxchange.org/?p=mailer.git;a=commitdiff_plain;h=167d6691adee23b37fc0b18d0ad465e9f2d31331;ds=sidebyside Final fixes for SQL execution --- diff --git a/inc/extensions.php b/inc/extensions.php index 61fe0afa93..1439e97a8c 100644 --- a/inc/extensions.php +++ b/inc/extensions.php @@ -127,7 +127,7 @@ function LOAD_EXTENSION ($ext_name, $EXT_LOAD_MODE = "", $EXT_VER = "", $dry_run function EXTENSION_REGISTER ($ext_name, $task_id, $dry_run = false, $logout = true) { global $UPDATE_NOTES, $INC_POOL, $cacheInstance; global $EXT_VER_HISTORY, $NOTES, $EXT_ALWAYS_ACTIVE, $EXT_VERSION; - global $EXT_UPDATE_DEPENDS, $SQLs; + global $EXT_UPDATE_DEPENDS; // This shall never do a non-admin user! if (!IS_ADMIN()) return false; @@ -225,7 +225,7 @@ function EXTENSION_REGISTER ($ext_name, $task_id, $dry_run = false, $logout = tr // "Dry-run-mode" activated? if (!$dry_run) { // Run installation pre-installation filters - RUN_FILTER('pre_extension_installed', false, array('dry_run' => $dry_run, 'sqls' => $SQLs)); + RUN_FILTER('pre_extension_installed', array('dry_run' => $dry_run, 'sqls' => $SQLs)); // Register extension $result = SQL_QUERY_ESC("INSERT INTO "._MYSQL_PREFIX."_extensions (ext_name, ext_active, ext_version) VALUES ('%s','%s','%s')", @@ -280,7 +280,7 @@ function EXTENSION_REGISTER ($ext_name, $task_id, $dry_run = false, $logout = tr // Run SQL queries for given extension id // @TODO Change from ext_id to ext_name (not just even the variable! ;-) ) function EXTENSION_RUN_SQLS ($ext_id, $load_mode) { - global $cacheInstance, $SQLs; + global $cacheInstance; // This shall never do a non-admin user! if (!IS_ADMIN()) return false; @@ -419,7 +419,7 @@ function GET_EXT_VERSION ($ext_name) { function EXTENSION_UPDATE ($ext_name, $ext_ver, $dry_run = false) { // This shall never do a non-admin user! global $cacheInstance, $UPDATE_NOTES, $NOTES, $EXT_VER_HISTORY; - global $EXT_UPDATE_DEPENDS, $EXT_VERSION, $INC_POOL, $cacheArray; + global $EXT_UPDATE_DEPENDS, $EXT_VERSION, $INC_POOL, $cacheArray, $SQLs; // Init arrays $SQLs = array(); $INC_POOL = array(); @@ -512,7 +512,7 @@ function EXTENSION_UPDATE ($ext_name, $ext_ver, $dry_run = false) { // In "dry-run" mode return array with SQL commands return $SQLs; } - } + } // END - if } // Output verbose SQL table for extension