From 5866fa98acdfbcbc90c8bc5938799fdb6b7cd374 Mon Sep 17 00:00:00 2001 From: Thijs Scheepers Date: Wed, 10 Dec 2014 11:21:36 +0100 Subject: [PATCH] Update BugsnagErrorHandler.php --- Lib/BugsnagErrorHandler.php | 10 ++++++++-- 1 file changed, 8 insertions(+), 2 deletions(-) diff --git a/Lib/BugsnagErrorHandler.php b/Lib/BugsnagErrorHandler.php index ed5d550..adaae80 100644 --- a/Lib/BugsnagErrorHandler.php +++ b/Lib/BugsnagErrorHandler.php @@ -37,12 +37,18 @@ public static function getBugsnag() { static $bugsnag = null; if (null === $bugsnag) { - $bugsnag = new Bugsnag_Client(Configure::read('BugsnagCakephp.apikey')); + $bugsnag = new \Bugsnag_Client(Configure::read('BugsnagCakephp.apikey')); + $bugsnag->setBatchSending(false); + $bugsnag->setNotifier(array( + 'name' => 'Bugsnag CakePHP', + 'version' => '0.1.0', + 'url' => 'https://github.com/Label305/bugsnag-cakephp' + )); } return $bugsnag; } - + public static function handleError($code, $description, $file = null, $line = null, $context = null) { static::getBugsnag()->errorHandler($code, $description, $file, $line, $context);