moving out doit from minify to cloudcmd

This commit is contained in:
coderaiser 2012-12-27 05:23:08 -05:00
parent b2463867d7
commit 02f8648c19
3 changed files with 73 additions and 80 deletions

View file

@ -91,11 +91,13 @@
CloudServer.Socket = main.socket;
/* базовая инициализация */
CloudServer.init = (function(pAppCachProcessing){
CloudServer.init = function(pAppCachProcessing){
var lConfig = this.Config,
lMinify = this.Minify,
lCache = this.Cache,
lAppCache = this.AppCache;
lAppCache = this.AppCache,
lMinifyAllowed = lConfig.minification;
/* Переменная в которой храниться кэш*/
lCache.setAllowed(lConfig.cache.allowed);
@ -103,15 +105,15 @@
/* Change default parameters of
* js/css/html minification
*/
lMinify.setAllowed(lConfig.minification);
lMinify.setAllowed(lMinifyAllowed);
/* Если нужно минимизируем скрипты */
lMinify._allowed = lMinify.doit();
Util.exec(CloudServer.minimize, lMinifyAllowed);
/* создаём файл app cache */
if( lConfig.appcache && lAppCache && lConfig.server )
Util.exec( pAppCachProcessing );
});
};
/**
@ -135,6 +137,7 @@
CloudServer.indexProcessing = pProcessing.index;
CloudServer.rest = pProcessing.rest;
CloudServer.route = pProcessing.route;
CloudServer.minimize = pProcessing.minimize;
this.init(pProcessing.appcache);