urlParser.resolve requires urls to be strings

In some instances the url or this.options.baseUrl are objects or null, this protects against url.js from throwing an error.