changed the way of getting github application id

This commit is contained in:
coderaiser 2012-12-13 05:37:02 -05:00
parent 288240726c
commit ce5b7baaa4
4 changed files with 11 additions and 27 deletions

View file

@ -1,3 +1,9 @@
2012.*.*, Version 0.1.9
* Changed the way of getting github application id
(now it's just from config, rest api removed).
2012.12.12, Version 0.1.8
* Added ability to shutdown Cloud Commander

View file

@ -3,7 +3,7 @@
"appcache" : false,
"cache" : {"allowed" : false},
"minification" : {
"js" : true,
"js" : false,
"css" : true,
"html" : true,
"img" : true

View file

@ -43,13 +43,9 @@ var CloudCommander, Util, DOM, $, Github, cb;
}
function setConfig(pCallBack){
DOM.ajax({
url : GitHubIdURL,
success : function(pData){
GitHub_ID = pData;
Util.exec(pCallBack);
}
cloudcmd.getConfig(function(pConfig){
GitHub_ID = pConfig.github_key;
Util.exec(pCallBack);
});
}

View file

@ -105,30 +105,12 @@
*/
function onGET(pParams){
var lResult = {error: 'command not found'},
lCmd = pParams.command,
lConfig = main.config,
lEnv = process.env,
lEnvKey,
lConfigKey;
lCmd = pParams.command;
switch(lCmd){
case '':
lResult = {info: 'Cloud Commander API v1'};
break;
case 'github_key':
lEnvKey = lEnv.github_key;
lConfigKey = lConfig.github_key,
lResult = lEnvKey || lConfigKey;
break;
case 'dropbox_chooser_key':
lEnvKey = lEnv.dropbox_chooser_key;
lConfigKey = lConfig.dropbox_chooser_key;
lResult = lEnvKey || lConfigKey;
break;
case 'kill':
pParams.data = {