$window.location.origin
returns the wrong value on IE.
The origin property returns the protocol, hostname and port number of a URL.
Example
url: http://localhost:8080/products/search
Chrome:
$window.location.origin
returns http://localhost:8080
IE:
$window.location.origin
returns http://localhost:8080/products/search
How can I have the right value on IE?