Fixed trailing slash issues