remove tailing / in path