Fixed problem with duplicate / if rootUrl is empty