Fix URL joining

Should use `url.resolve` rather than `path.join`