mirror of
https://github.com/invoiceninja/invoiceninja.git
synced 2024-09-21 00:41:34 +02:00
Set nullable type for Backup
This commit is contained in:
parent
c581c183ac
commit
7604bf28e6
@ -27,8 +27,11 @@ class InvoiceHistoryTransformer extends EntityTransformer
|
||||
'activity',
|
||||
];
|
||||
|
||||
public function transform(Backup $backup)
|
||||
public function transform(?Backup $backup)
|
||||
{
|
||||
if(!$backup)
|
||||
return [];
|
||||
|
||||
return [
|
||||
'id' => $this->encodePrimaryKey($backup->id),
|
||||
'activity_id' => $this->encodePrimaryKey($backup->activity_id),
|
||||
|
Loading…
Reference in New Issue
Block a user