Skip to content

Commit 44e6c8d

Browse files
committed
fix(backup): null pointer
1 parent 33820f0 commit 44e6c8d

1 file changed

Lines changed: 1 addition & 1 deletion

File tree

services/project/backup.go

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -280,7 +280,7 @@ func (b *BackupDB) format() (*BackupFormat, error) {
280280
repoName,
281281
}
282282

283-
if o.TaskParams.InventoryID != nil {
283+
if o.TaskParams != nil && o.TaskParams.InventoryID != nil {
284284
schedules[i].TaskParams.InventoryName, _ = findNameByID[db.Inventory](*o.TaskParams.InventoryID, b.inventories)
285285
}
286286
}

0 commit comments

Comments
 (0)