added debug method to util

This commit is contained in:
coderaiser 2012-11-29 07:34:39 -05:00
parent 85400edf48
commit 91ac8802fe
5 changed files with 43 additions and 11 deletions

View file

@ -180,8 +180,7 @@ var CloudCommander, Util, DOM, CloudFunc;
*/
DOM.Cache = function(){
/* приватный переключатель возможности работы с кэшем */
var CacheAllowed,
Data = {};
var CacheAllowed;
/* функция проверяет возможно ли работать с кэшем каким-либо образом */
this.isAllowed = function(){
@ -265,6 +264,7 @@ var CloudCommander, Util, DOM, CloudFunc;
DOM.Cache = new DOM.Cache();
/**
* Function gets id by src
* @param pSrc
@ -721,14 +721,14 @@ var CloudCommander, Util, DOM, CloudFunc;
*/
DOM.getCurrentFile = function(){
var lCurrent = DOM.getByClass(getCurrentFile())[0];
if(!lCurrent)
if(!lCurrent){
DOM.addCloudStatus({
code : -1,
msg : 'Error: can not find ' +
'CurrentFile ' +
'in getCurrentFile'
});
}
return lCurrent;
};

View file

@ -110,6 +110,7 @@ var CloudCommander, Util, DOM, $, Github, cb;
});
}
else
//window.open('welcome.html', 'welcome','width=300,height=200,menubar=yes,status=yes')">
window.location =
'https://github.com/login/oauth/authorize?client_id=' +
CLIENT_ID + '&&scope=repo,user,gist';