Use Uri class instead of makeRelativeUrlAbsolute.