]> git.mxchange.org Git - mailer.git/blobdiff - inc/modules/admin/what-config_mods.php
Rewrote some 'manual' cache rebuilding to use rebuildCache()
[mailer.git] / inc / modules / admin / what-config_mods.php
index e352214c2090bb24ec7fc07fbccc72bf851ab6ba..cd5e40d9ba62f20fc887cfdbb85ae89f2893a458 100644 (file)
@@ -16,8 +16,8 @@
  * $Author::                                                          $ *
  * -------------------------------------------------------------------- *
  * Copyright (c) 2003 - 2009 by Roland Haeder                           *
- * Copyright (c) 2009 - 2011 by Mailer Developer Team                   *
- * For more information visit: http://www.mxchange.org                  *
+ * Copyright (c) 2009 - 2012 by Mailer Developer Team                   *
+ * For more information visit: http://mxchange.org                      *
  *                                                                      *
  * This program is free software; you can redistribute it and/or modify *
  * it under the terms of the GNU General Public License as published by *
@@ -92,7 +92,17 @@ if (isFormSent('edit')) {
                $id = bigintval($id);
 
                // Update module
-               addSql(SQL_QUERY_ESC("UPDATE `{?_MYSQL_PREFIX?}_mod_reg` SET `title`='%s', `locked`='%s', `hidden`='%s', `admin_only`='%s', `mem_only`='%s' WHERE `id`=%s LIMIT 1",
+               addSql(SQL_QUERY_ESC("UPDATE
+       `{?_MYSQL_PREFIX?}_mod_reg`
+SET
+       `title`='%s',
+       `locked`='%s',
+       `hidden`='%s',
+       `admin_only`='%s',
+       `mem_only`='%s'
+WHERE
+       `id`=%s
+LIMIT 1",
                        array(
                                postRequestElement('title', $id),
                                postRequestElement('locked', $id),
@@ -107,9 +117,7 @@ if (isFormSent('edit')) {
        runFilterChain('run_sqls');
 
        // Remove cache file if version matches
-       if (isExtensionInstalledAndNewer('cache', '0.1.2')) {
-               if ($GLOBALS['cache_instance']->loadCacheFile('modules')) $GLOBALS['cache_instance']->removeCacheFile();
-       } // END - if
+       rebuildCache('modules', 'modules');
 
        // Entries updated
        displayMessage('{--ADMIN_MODS_CHANGED--}');