Skip to content

Conversation

@alexkhm32
Copy link

@alexkhm32 alexkhm32 commented Nov 14, 2025

🎫 Ticket Reference

📝 Changes

  • Add total count, limit and offset usage.
  • Add more convenient and flexible errors.
  • Add missing error propagation to middleware.
  • Fix inappropriate status codes
  • Quality of life improvement.

@eugene-burenkov eugene-burenkov self-requested a review December 1, 2025 09:01
}

func (r *PostRepository) List(ctx context.Context, filters domain.PostFilters) ([]model.Post, error) {
tx := r.db.WithContext(ctx).Offset(int(filters.Offset)).Limit(int(filters.Limit))

Check failure

Code scanning / CodeQL

Incorrect conversion between integer types High

Incorrect conversion of a signed 64-bit integer from strconv.ParseInt to a lower bit size type int without an upper bound check.
}

func (r *PostRepository) List(ctx context.Context, filters domain.PostFilters) ([]model.Post, error) {
tx := r.db.WithContext(ctx).Offset(int(filters.Offset)).Limit(int(filters.Limit))

Check failure

Code scanning / CodeQL

Incorrect conversion between integer types High

Incorrect conversion of a signed 64-bit integer from strconv.ParseInt to a lower bit size type int without an upper bound check.
@oleksandrkhmil-nixs
Copy link
Collaborator

Moved to #29

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants