Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

code hygiene: add missing nil check and corresponding tests for query handlers #3462

Merged
merged 2 commits into from
Apr 17, 2023

Conversation

crodriguezvega
Copy link
Contributor

@crodriguezvega crodriguezvega commented Apr 16, 2023

Description

closes: #XXXX

Commit Message / Changelog Entry

chore: add missing `nil` check in gprc handlers

see the guidelines for commit messages. (view raw markdown for examples)


Before we can merge this PR, please make sure that all the following items have been
checked off. If any of the checklist items are not applicable, please leave them but
write a little note why.

  • Targeted PR against correct branch (see CONTRIBUTING.md).
  • Linked to Github issue with discussion and accepted design OR link to spec that describes this work.
  • Code follows the module structure standards and Go style guide.
  • Wrote unit and integration tests.
  • Updated relevant documentation (docs/) or specification (x/<module>/spec/).
  • Added relevant godoc comments.
  • Provide a commit message to be used for the changelog entry in the PR description for review.
  • Re-reviewed Files changed in the Github PR explorer.
  • Review Codecov Report in the comment section below once CI passes.

@codecov-commenter
Copy link

codecov-commenter commented Apr 16, 2023

Codecov Report

Merging #3462 (f36ae66) into main (c043dbd) will increase coverage by 0.21%.
The diff coverage is 80.00%.

Additional details and impacted files

Impacted file tree graph

@@            Coverage Diff             @@
##             main    #3462      +/-   ##
==========================================
+ Coverage   78.54%   78.76%   +0.21%     
==========================================
  Files         181      181              
  Lines       12581    12586       +5     
==========================================
+ Hits         9882     9913      +31     
+ Misses       2265     2248      -17     
+ Partials      434      425       -9     
Impacted Files Coverage Δ
modules/core/keeper/msg_server.go 54.78% <50.00%> (-0.02%) ⬇️
modules/apps/29-fee/keeper/grpc_query.go 90.52% <100.00%> (+14.59%) ⬆️

@@ -131,6 +131,7 @@ func (k Keeper) ConnectionOpenTry(goCtx context.Context, msg *connectiontypes.Ms
// ConnectionOpenAck defines a rpc handler method for MsgConnectionOpenAck.
func (k Keeper) ConnectionOpenAck(goCtx context.Context, msg *connectiontypes.MsgConnectionOpenAck) (*connectiontypes.MsgConnectionOpenAckResponse, error) {
ctx := sdk.UnwrapSDKContext(goCtx)

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

This extra space makes it consistent with the rest of message handlers in this file. :)

@crodriguezvega crodriguezvega changed the title code hygiene: add missing nil check in gprc handlers code hygiene: add missing nil check and corresponding tests in query handlers Apr 16, 2023
@crodriguezvega crodriguezvega changed the title code hygiene: add missing nil check and corresponding tests in query handlers code hygiene: add missing nil check and corresponding tests for query handlers Apr 16, 2023
@crodriguezvega crodriguezvega merged commit 06d71ba into main Apr 17, 2023
@crodriguezvega crodriguezvega deleted the carlos/add-missing-nil-check branch April 17, 2023 11:38
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.

5 participants