try to remove trailing slash