fix: handle trailing slashes on root route and avoid crashes due to AssertionErrors thrown by odd requests
#1960
+76
−9