Fix up route parameter validation

Closes #3169
-Replace javascript methods that are not available on all
 supported browsers with lodash methods.
-Add returns to transitionTo calls in cases where the model
 hook should stop executing immediately.