Advertisement
Guest User

Untitled

a guest
Oct 3rd, 2014
394
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
  1. 'use strict';
  2. myApp.factory('$exceptionHandler', ['$injector', function ($injector) {
  3.         function log(exception, cause) {
  4.             Airbrake.push({
  5.                 error : {
  6.                     message : exception.toString(),
  7.                     stack : exception.stack
  8.                 },
  9.                 params : {
  10.                     user : $user,
  11.                     history : $history
  12.                 }
  13.             });
  14.         }
  15.         return( log );
  16.     }]
  17. );
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement