Skip to content

Commit b2adf15

Browse files
committed
wip
1 parent 489c17b commit b2adf15

File tree

2 files changed

+8
-2
lines changed

2 files changed

+8
-2
lines changed

CHANGELOG.md

Lines changed: 4 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -2,6 +2,10 @@
22

33
All notable changes to `flare-client-php` will be documented in this file
44

5+
## 1.9.1 - 2021-09-13
6+
7+
- let `report` return the created report
8+
59
## 1.9.0 - 2021-09-13
610

711
- add report tracking uuid

src/Flare.php

Lines changed: 4 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -190,10 +190,10 @@ public function applicationPath(string $applicationPath)
190190
return $this;
191191
}
192192

193-
public function report(Throwable $throwable, callable $callback = null)
193+
public function report(Throwable $throwable, callable $callback = null): ?Report
194194
{
195195
if (! $this->shouldSendReport($throwable)) {
196-
return;
196+
return null;
197197
}
198198

199199
$report = $this->createReport($throwable);
@@ -203,6 +203,8 @@ public function report(Throwable $throwable, callable $callback = null)
203203
}
204204

205205
$this->sendReportToApi($report);
206+
207+
return $report;
206208
}
207209

208210
protected function shouldSendReport(Throwable $throwable): bool

0 commit comments

Comments
 (0)