quick routing code validation for a better error message