Fixing slashes, so url.resolve returns right url