Deletes extra space before closing bracket in routes