Fixed a bug that caused 404 errors when attempting to access a page with a trailing slash