Mahor rewrite:
[mailer.git] / inc / gen_sql_patches.php
index 18faa6fd8cfdaa8645dfdcf85b71c78c8c6e4c25..98337f0f3c55565e050416eeffe2223629929e26 100644 (file)
@@ -41,7 +41,7 @@ if (ereg(basename(__FILE__), $_SERVER['PHP_SELF'])) {
 if (GET_EXT_VERSION("sql_patches") < "0.3.6") return false;
 
 // Check if there is no scrambling string
-if (empty($_CONFIG['pass_scramble'])) {
+if (getConfig('pass_scramble') == "") {
        // Generate 40 chars long scramble string
        $scrambleString = genScrambleString(40);
 
@@ -55,7 +55,7 @@ if (empty($_CONFIG['pass_scramble'])) {
 } // END - if
 
 // Check if there is no master salt string
-if (empty($_CONFIG['master_salt'])) {
+if (getConfig('master_salt') == "") {
        // Generate the master salt which is the first chars minus 40 chars of this random hash
        // We do an extra scrambling here...
        $masterSalt = scrambleString(substr(generateHash(GEN_PASS(mt_rand(128, 256))), 0, -40));
@@ -69,7 +69,7 @@ if (empty($_CONFIG['master_salt'])) {
        unset($masterSalt);
 } // END - if
 
-if (empty($_CONFIG['file_hash'])) {
+if (getConfig('file_hash') == "") {
        // Create filename from hashed random string
        $file_hash = generateHash(sha1(GEN_PASS(mt_rand(128, 256))));
        $file = PATH."inc/.secret/.".$file_hash;