Fixes #118. Fix for incorrect redirect of attempt to create new custom object

Fixes #118. Fix for incorrect redirect of attempt to create new custom object when validation fails on duplicate name.
Fix to catch all synchronous errors.