| console.log('XOS Helpers Module') |
| angular.module('bugSnag', []).factory('$exceptionHandler', function () { |
| return function (exception, cause) { |
| Bugsnag.notifyException(exception, {diagnostics:{cause: cause}}); |
| console.error(exception, cause, exception.stack); |
| function config($httpProvider, $interpolateProvider, $resourceProvider) { |
| $httpProvider.interceptors.push('SetCSRFToken'); |
| $interpolateProvider.startSymbol('{$'); |
| $interpolateProvider.endSymbol('$}'); |
| // NOTE http://www.masnun.com/2013/09/18/django-rest-framework-angularjs-resource-trailing-slash-problem.html |
| $resourceProvider.defaults.stripTrailingSlashes = false; |