aboutsummaryrefslogtreecommitdiff
path: root/js/io/system/coreioapi.js
diff options
context:
space:
mode:
authorNivesh Rajbhandari2012-04-09 16:05:16 -0700
committerNivesh Rajbhandari2012-04-09 16:05:16 -0700
commit36df4f454d64c7b43062835495425021ce955b05 (patch)
tree9ebbe37bf22cb5280882a0ef5b95196fcf163251 /js/io/system/coreioapi.js
parent952e0b2c28af081041fa8987c3e865b931d052fa (diff)
parentbd43ce383b050d03b0f92cc923c517febc66ca28 (diff)
downloadninja-36df4f454d64c7b43062835495425021ce955b05.tar.gz
Merge branch 'refs/heads/ninja-internal' into AllFixes
Diffstat (limited to 'js/io/system/coreioapi.js')
-rwxr-xr-xjs/io/system/coreioapi.js4
1 files changed, 2 insertions, 2 deletions
diff --git a/js/io/system/coreioapi.js b/js/io/system/coreioapi.js
index b0ffe2d8..a06f45c6 100755
--- a/js/io/system/coreioapi.js
+++ b/js/io/system/coreioapi.js
@@ -1085,14 +1085,14 @@ exports.CoreIoApi = Montage.create(Component, {
1085 isValidUri:{ 1085 isValidUri:{
1086 value: function(uri){ 1086 value: function(uri){
1087 var isWindowsUri=false, isUnixUri=false,status=false; 1087 var isWindowsUri=false, isUnixUri=false,status=false;
1088 if(uri !== ""){ 1088 if((uri !== null) && (uri !== "")){
1089 uri = uri.replace(/^\s+|\s+$/g,""); // strip any leading or trailing spaces 1089 uri = uri.replace(/^\s+|\s+$/g,""); // strip any leading or trailing spaces
1090 1090
1091 //for local machine folder uri 1091 //for local machine folder uri
1092 isWindowsUri = /^([a-zA-Z]:)([\\/][^<>:"/\\|?*]+)*[\\/]?$/gi.test(uri); 1092 isWindowsUri = /^([a-zA-Z]:)([\\/][^<>:"/\\|?*]+)*[\\/]?$/gi.test(uri);
1093 isUnixUri = /^(\/)?(\/(?![.])[^/]*)*\/?$/gi.test(uri);//folders beginning with . are hidden on Mac / Unix 1093 isUnixUri = /^(\/)?(\/(?![.])[^/]*)*\/?$/gi.test(uri);//folders beginning with . are hidden on Mac / Unix
1094 status = isWindowsUri || isUnixUri; 1094 status = isWindowsUri || isUnixUri;
1095 if(isWindowsUri && isUnixUri){status = false;} 1095 if((uri === "") || (isWindowsUri && isUnixUri)){status = false;}
1096 } 1096 }
1097 return status; 1097 return status;
1098 } 1098 }