mirror of
https://github.com/coderaiser/cloudcmd.git
synced 2026-07-18 08:56:20 +00:00
refactor(dom) getCurrentData
This commit is contained in:
parent
325cf98da2
commit
f528c351fa
1 changed files with 2 additions and 3 deletions
|
|
@ -1473,6 +1473,7 @@ var CloudCmd, Util, DOM, CloudFunc, Dialog;
|
|||
this.getCurrentData = function(pCallBack, pCurrentFile) {
|
||||
var lParams,
|
||||
lCurrentFile = pCurrentFile ? pCurrentFile : this.getCurrentFile(),
|
||||
lPath = DOM.getCurrentPath(lCurrentFile),
|
||||
|
||||
lFunc = function(pData) {
|
||||
var lExt = '.json',
|
||||
|
|
@ -1499,9 +1500,7 @@ var CloudCmd, Util, DOM, CloudFunc, Dialog;
|
|||
error : pCallBack.error
|
||||
};
|
||||
|
||||
var lName = DOM.getCurrentName(lCurrentFile);
|
||||
|
||||
DOM.getDataFromCache(lName, function(data) {
|
||||
DOM.getDataFromCache(lPath, function(data) {
|
||||
if (data)
|
||||
lFunc(data);
|
||||
else
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue