Fixed a small bug related to trailing slashes.