Skip to content

Commit

Permalink
Make linter happy
Browse files Browse the repository at this point in the history
  • Loading branch information
AlekSi committed Apr 3, 2023
1 parent 10552a5 commit df50655
Show file tree
Hide file tree
Showing 2 changed files with 4 additions and 4 deletions.
4 changes: 2 additions & 2 deletions internal/handlers/pg/msg_count.go
Original file line number Diff line number Diff line change
Expand Up @@ -59,14 +59,14 @@ func (h *Handler) MsgCount(ctx context.Context, msg *wire.OpMsg) (*wire.OpMsg, e
return nil, err
}

var skip int64
var skip, limit int64

if s, _ := document.Get("skip"); s != nil {
if skip, err = common.GetSkipParam("count", s); err != nil {
return nil, err
}
}

var limit int64
if l, _ := document.Get("limit"); l != nil {
if limit, err = common.GetLimitParam("count", l); err != nil {
return nil, err
Expand Down
4 changes: 2 additions & 2 deletions internal/handlers/tigris/msg_count.go
Original file line number Diff line number Diff line change
Expand Up @@ -58,14 +58,14 @@ func (h *Handler) MsgCount(ctx context.Context, msg *wire.OpMsg) (*wire.OpMsg, e
return nil, err
}

var skip int64
var skip, limit int64

if s, _ := document.Get("skip"); s != nil {
if skip, err = common.GetSkipParam("count", s); err != nil {
return nil, err
}
}

var limit int64
if l, _ := document.Get("limit"); l != nil {
if limit, err = common.GetLimitParam("count", l); err != nil {
return nil, err
Expand Down

0 comments on commit df50655

Please sign in to comment.