fixed condition where domain ends in '/'