more precise routes
valid ip check returning false when exception occurs