refactor: remove unused code related to whitelisted assets

This commit is contained in:
Prad Nukala
2024-09-27 20:58:05 -04:00
parent 88a3d9da1c
commit 92ff87cc2c
57 changed files with 25331 additions and 15090 deletions
+42 -1
View File
@@ -19,7 +19,8 @@ import (
const _ = grpc.SupportPackageIsVersion7
const (
Msg_UpdateParams_FullMethodName = "/macaroon.v1.Msg/UpdateParams"
Msg_UpdateParams_FullMethodName = "/macaroon.v1.Msg/UpdateParams"
Msg_AuthorizeService_FullMethodName = "/macaroon.v1.Msg/AuthorizeService"
)
// MsgClient is the client API for Msg service.
@@ -30,6 +31,9 @@ type MsgClient interface {
//
// Since: cosmos-sdk 0.47
UpdateParams(ctx context.Context, in *MsgUpdateParams, opts ...grpc.CallOption) (*MsgUpdateParamsResponse, error)
// AuthorizeService asserts the given controller is the owner of the given
// address.
AuthorizeService(ctx context.Context, in *MsgIssueMacaroon, opts ...grpc.CallOption) (*MsgIssueMacaroonResponse, error)
}
type msgClient struct {
@@ -49,6 +53,15 @@ func (c *msgClient) UpdateParams(ctx context.Context, in *MsgUpdateParams, opts
return out, nil
}
func (c *msgClient) AuthorizeService(ctx context.Context, in *MsgIssueMacaroon, opts ...grpc.CallOption) (*MsgIssueMacaroonResponse, error) {
out := new(MsgIssueMacaroonResponse)
err := c.cc.Invoke(ctx, Msg_AuthorizeService_FullMethodName, in, out, opts...)
if err != nil {
return nil, err
}
return out, nil
}
// MsgServer is the server API for Msg service.
// All implementations must embed UnimplementedMsgServer
// for forward compatibility
@@ -57,6 +70,9 @@ type MsgServer interface {
//
// Since: cosmos-sdk 0.47
UpdateParams(context.Context, *MsgUpdateParams) (*MsgUpdateParamsResponse, error)
// AuthorizeService asserts the given controller is the owner of the given
// address.
AuthorizeService(context.Context, *MsgIssueMacaroon) (*MsgIssueMacaroonResponse, error)
mustEmbedUnimplementedMsgServer()
}
@@ -67,6 +83,9 @@ type UnimplementedMsgServer struct {
func (UnimplementedMsgServer) UpdateParams(context.Context, *MsgUpdateParams) (*MsgUpdateParamsResponse, error) {
return nil, status.Errorf(codes.Unimplemented, "method UpdateParams not implemented")
}
func (UnimplementedMsgServer) AuthorizeService(context.Context, *MsgIssueMacaroon) (*MsgIssueMacaroonResponse, error) {
return nil, status.Errorf(codes.Unimplemented, "method AuthorizeService not implemented")
}
func (UnimplementedMsgServer) mustEmbedUnimplementedMsgServer() {}
// UnsafeMsgServer may be embedded to opt out of forward compatibility for this service.
@@ -98,6 +117,24 @@ func _Msg_UpdateParams_Handler(srv interface{}, ctx context.Context, dec func(in
return interceptor(ctx, in, info, handler)
}
func _Msg_AuthorizeService_Handler(srv interface{}, ctx context.Context, dec func(interface{}) error, interceptor grpc.UnaryServerInterceptor) (interface{}, error) {
in := new(MsgIssueMacaroon)
if err := dec(in); err != nil {
return nil, err
}
if interceptor == nil {
return srv.(MsgServer).AuthorizeService(ctx, in)
}
info := &grpc.UnaryServerInfo{
Server: srv,
FullMethod: Msg_AuthorizeService_FullMethodName,
}
handler := func(ctx context.Context, req interface{}) (interface{}, error) {
return srv.(MsgServer).AuthorizeService(ctx, req.(*MsgIssueMacaroon))
}
return interceptor(ctx, in, info, handler)
}
// Msg_ServiceDesc is the grpc.ServiceDesc for Msg service.
// It's only intended for direct use with grpc.RegisterService,
// and not to be introspected or modified (even as a copy)
@@ -109,6 +146,10 @@ var Msg_ServiceDesc = grpc.ServiceDesc{
MethodName: "UpdateParams",
Handler: _Msg_UpdateParams_Handler,
},
{
MethodName: "AuthorizeService",
Handler: _Msg_AuthorizeService_Handler,
},
},
Streams: []grpc.StreamDesc{},
Metadata: "macaroon/v1/tx.proto",