Update for unit tests and using the repo-id as a last
resort to the relative_url