Skip to content

Commit

Permalink
Merge pull request #19 from DN-Amsterdam/master
Browse files Browse the repository at this point in the history
Expose the Bugsnag Client through the BugsnagService
  • Loading branch information
sjelfull authored Jan 22, 2020
2 parents 7f3562e + eb6697f commit 19ec179
Showing 1 changed file with 9 additions and 4 deletions.
13 changes: 9 additions & 4 deletions src/services/BugsnagService.php
Original file line number Diff line number Diff line change
Expand Up @@ -84,13 +84,10 @@ public function breadcrumb ($text = '', $type = Breadcrumb::MANUAL_TYPE, $metaDa
$this->bugsnag->leaveBreadcrumb($text, $type, $metaData);
}

/*
* @return mixed
*/
/**
* @param $exception
*
* @return bool
* @return bool | void
*/
public function handleException ($exception)
{
Expand All @@ -101,6 +98,14 @@ public function handleException ($exception)
$this->bugsnag->notifyException($exception);
}

/**
* @return Client
*/
public function getClient () : Client
{
return $this->bugsnag;
}

public function isEnabled ()
{
return $this->settings->enabled && !empty($this->settings->serverApiKey);
Expand Down

0 comments on commit 19ec179

Please sign in to comment.