]> git.mxchange.org Git - mailer.git/blobdiff - inc/extensions-functions.php
Renamed templates + added some filters for mail order
[mailer.git] / inc / extensions-functions.php
index 8dfde689bd230f9bc3be134c47b29850ef740518..58127d2909bf965d7ce517a3d09bb0cf3ce8f6bf 100644 (file)
@@ -249,7 +249,7 @@ function registerExtension ($ext_name, $taskId, $isDryRun = FALSE, $ignoreUpdate
        initIncludePool('extension');
 
        // By default there is no failure
-       enableExtensionReportingFailure();
+       enableExtensionReportingFailure(FALSE);
 
        // Does this extension exists?
        //* DEBUG: */ logDebugMessage(__FUNCTION__, __LINE__, 'currName=' . getCurrentExtensionName() . ' - CALLING loadExtension() ...');
@@ -1053,7 +1053,7 @@ function createExtensionUpdateTask ($adminId, $ext_name, $ext_ver, $notes) {
                } // END - if
        } else {
                // Extension not there! :-(
-               reportBug(__FUNCTION__, __LINE__, sprintf("Extension <span class=\"data\">%s</span> not found but should be updated?", $ext_name));
+               reportBug(__FUNCTION__, __LINE__, sprintf('Extension <span class="data">%s</span> not found but should be updated?', $ext_name));
        }
 
        // Return task id
@@ -1063,7 +1063,7 @@ function createExtensionUpdateTask ($adminId, $ext_name, $ext_ver, $notes) {
 // Creates a new task for newly installed extension
 function createNewExtensionTask ($ext_name) {
        // Generate subject line
-       $subject = sprintf("[%s:]", $ext_name);
+       $subject = sprintf('[%s:]', $ext_name);
 
        // Get task id
        $taskId = determineTaskIdBySubject($subject);
@@ -1487,8 +1487,8 @@ function incrementExtensionUpdateIterator () {
        $GLOBALS['ext_depend_iterator'][getCurrentExtensionName()]++;
 }
 
-// Setter for EXT_REPORTS_FAILURE flag
-function enableExtensionReportingFailure ($reportsFailure = FALSE) {
+// Setter for EXT_REPORTS_FAILURE flag (default: extension reported installation failure)
+function enableExtensionReportingFailure ($reportsFailure = TRUE) {
        $GLOBALS['ext_reports_failure'] = (bool) $reportsFailure;
 }
 
@@ -2053,7 +2053,7 @@ function addSponsorMenuSql ($action, $what, $title, $active, $sort) {
                addExtensionSql($sql);
        } elseif (isDebugModeEnabled()) {
                // Double menus should be located and fixed!
-               logDebugMessage(__FUNCTION__, __LINE__, sprintf("Double sponsor menu action=%s,what=%s,title=%s,active=%s detected.", $action, $what, $title, $active));
+               logDebugMessage(__FUNCTION__, __LINE__, sprintf('Double sponsor menu action=%s,what=%s,title=%s,active=%s detected.', $action, $what, $title, $active));
        }
 }
 
@@ -2140,7 +2140,7 @@ function addExtensionChangeTableColumnSql ($tableName, $fromColumnName, $toColum
        assert(($fromColumnName != $columnSql) && ($toColumnName != $columnSql));
 
        // Is the column there?
-       if ((ifSqlTableColumnExists('{?_MYSQL_PREFIX?}_' . $tableName, $fromColumnName)) && (($fromColumnName == $toColumnName) || (!ifSqlTableColumnExists('{?_MYSQL_PREFIX?}_' . $tableName, $toColumnName, isInstaller())))) {
+       if ((ifSqlTableColumnExists('{?_MYSQL_PREFIX?}_' . $tableName, $fromColumnName, isInstaller())) && (($fromColumnName == $toColumnName) || (!ifSqlTableColumnExists('{?_MYSQL_PREFIX?}_' . $tableName, $toColumnName, isInstaller())))) {
                // Debug message
                //* DEBUG: */ logDebugMessage(__FUNCTION__, __LINE__, 'tableName=' . $tableName . ',fromColumnName=' . $fromColumnName . ',toColumnName=' . $toColumnName . ',columnSql=' . $columnSql);