[bugfix] fix panic during status delete loop by breaking out early on len(statuses) == 0 (#1317)
Signed-off-by: kim <grufwub@gmail.com> Signed-off-by: kim <grufwub@gmail.com>
This commit is contained in:
parent
67919204af
commit
2bf9bfa24f
|
@ -157,6 +157,10 @@ func (p *processor) Delete(ctx context.Context, account *gtsmodel.Account, origi
|
||||||
break
|
break
|
||||||
}
|
}
|
||||||
|
|
||||||
|
if len(statuses) == 0 {
|
||||||
|
break // reached end
|
||||||
|
}
|
||||||
|
|
||||||
for _, status := range statuses {
|
for _, status := range statuses {
|
||||||
// Ensure account is set
|
// Ensure account is set
|
||||||
status.Account = account
|
status.Account = account
|
||||||
|
|
Loading…
Reference in New Issue