Remove trailing spash from paths