fix(postgres):lab4 non-nil empty slice in ListStalePending

This commit is contained in:
Голиков Maximillian Антон
2026-10-22 18:16:07 +03:00
parent 46423faf8d
commit b6b3b94819
@@ -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,