Permalink
Browse files

allow for easy subclassing and add a CI stub

  • Loading branch information...
1 parent a1fb731 commit c3f8af0effc7f1f45fee2f40306af4da3adb1903 @rich rich committed Jan 24, 2010
Showing with 5 additions and 2 deletions.
  1. +2 −2 Services/Hoptoad.php
  2. +3 −0 Services/Hoptoad/CodeIgniter.php
View
@@ -96,7 +96,7 @@ public static function errorHandler($code, $message, $file, $line)
{
if ($code == E_STRICT && self::$reportESTRICT === false) return;
- $hoptoad = new Services_Hoptoad($code, $message, $file, $line, debug_backtrace());
+ $hoptoad = new self($code, $message, $file, $line, debug_backtrace());
$hoptoad->notify();
}
@@ -109,7 +109,7 @@ public static function errorHandler($code, $message, $file, $line)
*/
public static function exceptionHandler($exception)
{
- $hoptoad = new Services_Hoptoad(get_class($exception), $exception->getMessage(), $exception->getFile(), $exception->getLine(), $exception->getTrace());
+ $hoptoad = new self(get_class($exception), $exception->getMessage(), $exception->getFile(), $exception->getLine(), $exception->getTrace());
$hoptoad->notify();
}
@@ -0,0 +1,3 @@
+<?php
+class Services_Hoptoad_CodeIgniter extends Services_Hoptoad {
+}

0 comments on commit c3f8af0

Please sign in to comment.