]> git.mxchange.org Git - friendica.git/blobdiff - include/config.php
make 'PHP "register_argc_argv"' easier to translate, may require fix for po2php
[friendica.git] / include / config.php
old mode 100644 (file)
new mode 100755 (executable)
index 92694f5..4cff380
@@ -80,6 +80,7 @@ function set_config($family,$key,$value) {
        
        // manage array value
        $dbvalue = (is_array($value)?serialize($value):$value);
+       $dbvalue = (is_bool($value) ? intval($value) : $value);
 
        if(get_config($family,$key,true) === false) {
                $a->config[$family][$key] = $value;
@@ -162,7 +163,7 @@ function del_config($family,$key) {
        if(x($a->config[$family],$key))
                unset($a->config[$family][$key]);
        $ret = q("DELETE FROM `config` WHERE `cat` = '%s' AND `k` = '%s' LIMIT 1",
-               dbesc($cat),
+               dbesc($family),
                dbesc($key)
        );
        return $ret;