refactor(client) rmLastSlash

This commit is contained in:
coderaiser 2014-12-05 07:37:16 -05:00
parent bc4945f804
commit 2562fc37f1

View file

@ -259,7 +259,7 @@ var Util, DOM, CloudFunc, join;
Listeners.initKeysPanel();
/* Устанавливаем кэш корневого каталога */
dirPath = CloudFunc.rmLastSlash(dirPath) || '/';
dirPath = CloudFunc.rmLastSlash(dirPath);
Storage.get(dirPath, function(error, data) {
if (!data) {
@ -292,7 +292,7 @@ var Util, DOM, CloudFunc, join;
var panel = panelParam || Info.panel,
NEEDREFRESH = true,
path = DOM.getCurrentDirPath(panel),
notSlashlLink = CloudFunc.rmLastSlash(path) || '/';
notSlashlLink = CloudFunc.rmLastSlash(path);
CloudCmd.loadDir({
path : notSlashlLink,
@ -455,7 +455,7 @@ var Util, DOM, CloudFunc, join;
if (path !== parentPath) {
path = parentPath;
path = CloudFunc.rmLastSlash(path) || '/';
path = CloudFunc.rmLastSlash(path);
CloudCmd.loadDir({
path: path