A generic way to handle and log exceptions in angularjs