Skip to content

Commit

Permalink
Minor update in REST reponse
Browse files Browse the repository at this point in the history
  • Loading branch information
nguereza-tony committed Sep 19, 2023
1 parent 0738e88 commit 8997e3c
Showing 1 changed file with 3 additions and 1 deletion.
4 changes: 3 additions & 1 deletion src/Http/Response/RestResponse.php
Original file line number Diff line number Diff line change
Expand Up @@ -82,7 +82,9 @@ public function __construct(
$result['message'] = $message;
}

$result['data'] = $data;
if($data){
$result['data'] = $data;
}

if (!empty($extras)) {
$result = array_merge($result, $extras);
Expand Down

0 comments on commit 8997e3c

Please sign in to comment.