Skip to content

Commit

Permalink
Fix non existing property (#1360)
Browse files Browse the repository at this point in the history
  • Loading branch information
driesvints authored Jun 21, 2023
1 parent ff604e2 commit 4f9a3c3
Showing 1 changed file with 3 additions and 1 deletion.
4 changes: 3 additions & 1 deletion src/Watchers/ClientRequestWatcher.php
Original file line number Diff line number Diff line change
Expand Up @@ -226,7 +226,9 @@ protected function input(Request $request)
*/
protected function duration(Response $response)
{
if ($response->transferStats && $response->transferStats->getTransferTime()) {
if (property_exists($response, 'transferStats') &&
$response->transferStats &&
$response->transferStats->getTransferTime()) {
return floor($response->transferStats->getTransferTime() * 1000);
}
}
Expand Down

0 comments on commit 4f9a3c3

Please sign in to comment.