fixed route sanity check bugs