diff --git a/docs/docs/02-guide/03-hello-world.md b/docs/docs/02-guide/03-hello-world.md index 5f5c317a82..b0666d0d73 100644 --- a/docs/docs/02-guide/03-hello-world.md +++ b/docs/docs/02-guide/03-hello-world.md @@ -56,24 +56,23 @@ import ( "context" "fmt" + "hello/x/hello/types" + sdk "github.com/cosmos/cosmos-sdk/types" "google.golang.org/grpc/codes" "google.golang.org/grpc/status" - - "hello/x/hello/types" ) -func (k Keeper) SayHello(goCtx context.Context, req *types.QuerySayHelloRequest) (*types.QuerySayHelloResponse, error) { +func (q queryServer) SayHello(ctx context.Context, req *types.QuerySayHelloRequest) (*types.QuerySayHelloResponse, error) { if req == nil { return nil, status.Error(codes.InvalidArgument, "invalid request") } // Validation and Context unwrapping - ctx := sdk.UnwrapSDKContext(goCtx) + sdkCtx := sdk.UnwrapSDKContext(ctx) - _ = ctx + _ = sdkCtx // Custom Response - // highlight-next-line return &types.QuerySayHelloResponse{Name: fmt.Sprintf("Hello %s!", req.Name)}, nil } ``` diff --git a/docs/versioned_docs/version-v28/02-guide/03-hello-world.md b/docs/versioned_docs/version-v28/02-guide/03-hello-world.md index 5f5c317a82..b0666d0d73 100644 --- a/docs/versioned_docs/version-v28/02-guide/03-hello-world.md +++ b/docs/versioned_docs/version-v28/02-guide/03-hello-world.md @@ -56,24 +56,23 @@ import ( "context" "fmt" + "hello/x/hello/types" + sdk "github.com/cosmos/cosmos-sdk/types" "google.golang.org/grpc/codes" "google.golang.org/grpc/status" - - "hello/x/hello/types" ) -func (k Keeper) SayHello(goCtx context.Context, req *types.QuerySayHelloRequest) (*types.QuerySayHelloResponse, error) { +func (q queryServer) SayHello(ctx context.Context, req *types.QuerySayHelloRequest) (*types.QuerySayHelloResponse, error) { if req == nil { return nil, status.Error(codes.InvalidArgument, "invalid request") } // Validation and Context unwrapping - ctx := sdk.UnwrapSDKContext(goCtx) + sdkCtx := sdk.UnwrapSDKContext(ctx) - _ = ctx + _ = sdkCtx // Custom Response - // highlight-next-line return &types.QuerySayHelloResponse{Name: fmt.Sprintf("Hello %s!", req.Name)}, nil } ``` diff --git a/ignite/internal/tools/gen-mig-diffs/readme.md b/ignite/internal/tools/gen-mig-diffs/readme.md new file mode 100644 index 0000000000..a86566ea3e --- /dev/null +++ b/ignite/internal/tools/gen-mig-diffs/readme.md @@ -0,0 +1,64 @@ +