From 553fce7721cacfd13b6013fdcdd0243c90083b5e Mon Sep 17 00:00:00 2001 From: Ananya Sen Date: Wed, 1 Feb 2012 11:59:11 -0800 Subject: fixed reference to coreioapi cleaning up opening code view tabs Signed-off-by: Ananya Sen --- js/lib/NJUtils.js | 2 ++ 1 file changed, 2 insertions(+) (limited to 'js/lib/NJUtils.js') diff --git a/js/lib/NJUtils.js b/js/lib/NJUtils.js index d6548871..56c74b3b 100755 --- a/js/lib/NJUtils.js +++ b/js/lib/NJUtils.js @@ -206,6 +206,8 @@ exports.NJUtils = Object.create(Object.prototype, { ///// Return the last part of a path (e.g. filename) getFileNameFromPath : { value: function(path) { + path = path.replace(/[/\\]$/g,""); + path = path.replace(/\\/g,"/"); return path.substr(path.lastIndexOf('/') + 1); } } -- cgit v1.2.3