diff --git a/src/ng/urlUtils.js b/src/ng/urlUtils.js index e821c08a3e9f..5286a5ac7e99 100644 --- a/src/ng/urlUtils.js +++ b/src/ng/urlUtils.js @@ -81,8 +81,9 @@ function urlResolve(url) { hash: urlParsingNode.hash ? urlParsingNode.hash.replace(/^#/, '') : '', hostname: urlParsingNode.hostname, port: urlParsingNode.port, - pathname: urlParsingNode.pathname && urlParsingNode.pathname.charAt(0) === '/' ? - urlParsingNode.pathname : '/' + urlParsingNode.pathname + pathname: (urlParsingNode.protocol.indexOf('file')===0 && urlParsingNode.pathname.indexOf(':')===2)? + urlParsingNode.pathname.substring(3) : (urlParsingNode.pathname.charAt(0) === '/' ? + urlParsingNode.pathname : '/' + urlParsingNode.pathname) }; }