Don't return an error when report doesn't exist
This commit is contained in:
parent
da75aeecf2
commit
7e79308868
1 changed files with 1 additions and 1 deletions
|
|
@ -26,7 +26,7 @@ func ByID(ctx context.Context, public_id string, is_public bool) (*types.PublicR
|
|||
}
|
||||
log.Debug().Str("public_id", public_id).Int("len", len(reports)).Msg("querying for publicreport by ID")
|
||||
if len(reports) != 1 {
|
||||
return nil, fmt.Errorf("reports returned: %d", len(reports))
|
||||
return nil, nil
|
||||
}
|
||||
return reports[0], nil
|
||||
}
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue