diff --git a/backend/internal/storage/postgres/attachments.go b/backend/internal/storage/postgres/attachments.go index c824e8c7..915b1f13 100644 --- a/backend/internal/storage/postgres/attachments.go +++ b/backend/internal/storage/postgres/attachments.go @@ -136,7 +136,7 @@ func (r *AttachmentRepo) MarkFailed(ctx context.Context, id, errorCode string) e func (r *AttachmentRepo) ListStalePending(ctx context.Context, olderThan time.Time, limit int) ([]domain.Attachment, error) { if limit <= 0 { - return nil, nil + return []domain.Attachment{}, nil } const q = ` SELECT id, chat_id, owner_id, filename, content_type, size_bytes, sha256,