feature(minify) rm setAllowed

This commit is contained in:
coderaiser 2013-11-05 11:04:24 +00:00
parent 7ac3b1d564
commit 948dfcab59
3 changed files with 19 additions and 54 deletions

View file

@ -166,25 +166,17 @@
function readConfig(pCallBack) {
fs.readFile(CONFIG_PATH, function(pError, pData) {
var msg, status;
if (!pError) {
status = 'ok';
var lStr = pData.toString(),
lReadedConf = Util.parseJSON(lStr);
if (!Config.minify)
main.config = Config = lReadedConf;
Util.tryCatchLog(function() {
Config.minify = lReadedConf.minify;
Config.cache = lReadedConf.cache;
Minify.setAllowed(Config.minify);
});
}
else
var msg, status, str, readed;
if (pError)
status = 'error';
else {
status = 'ok';
str = pData.toString(),
readed = Util.parseJSON(str);
main.config = Config = readed;
}
msg = CloudFunc.formatMsg('read', 'config', status);
Util.log(msg);