diff --git a/lib/browser-plus-view.coffee b/lib/browser-plus-view.coffee index 1bfa597..7600696 100644 --- a/lib/browser-plus-view.coffee +++ b/lib/browser-plus-view.coffee @@ -327,7 +327,7 @@ class BrowserPlusView extends View else localhostPattern = ///^ (http://)? - localhost + ([a-zA-Z0-9]*) ///i if url.search(localhostPattern) < 0 and url.indexOf('.') < 0 url = "http://www.google.com/search?as_q=#{url}" @@ -337,8 +337,8 @@ class BrowserPlusView extends View url = url.replace(/\\/g,"/") else url = URL.format(urls) - else if url.indexOf('localhost') isnt -1 - url = url.replace(localhostPattern,'http://127.0.0.1') + #else if url.indexOf('localhost') isnt -1 + # url = url.replace(localhostPattern,'http://127.0.0.1') else urls.protocol = 'http' url = URL.format(urls) diff --git a/lib/browser-plus.coffee b/lib/browser-plus.coffee index 83eb0a7..09b5897 100644 --- a/lib/browser-plus.coffee +++ b/lib/browser-plus.coffee @@ -48,7 +48,7 @@ module.exports = BrowserPlus = url.indexOf('browser-plus~') is 0 ) localhostPattern = ///^ (http://)? - localhost + ([a-zA-Z0-9]*) ///i return false unless BrowserPlusModel.checkUrl(url) # check if it need to be open in same window @@ -61,7 +61,7 @@ module.exports = BrowserPlus = pane.activateItem(editor) return editor - url = url.replace(localhostPattern,'http://127.0.0.1') + #url = url.replace(localhostPattern,'http://127.0.0.1') new BrowserPlusModel {browserPlus:@,url:url,opt:opt} # Events subscribed to in atom's system can be easily cleaned up with a CompositeDisposable