mirror of
https://github.com/0glabs/0g-chain.git
synced 2024-12-26 16:25:21 +00:00
23 lines
494 B
Go
23 lines
494 B
Go
package keeper
|
|
|
|
import (
|
|
"context"
|
|
|
|
"github.com/0glabs/0g-chain/x/das/v1/types"
|
|
sdk "github.com/cosmos/cosmos-sdk/types"
|
|
)
|
|
|
|
var _ types.QueryServer = Keeper{}
|
|
|
|
func (k Keeper) NextRequestID(
|
|
c context.Context,
|
|
_ *types.QueryNextRequestIDRequest,
|
|
) (*types.QueryNextRequestIDResponse, error) {
|
|
ctx := sdk.UnwrapSDKContext(c)
|
|
nextRequestID, err := k.GetNextRequestID(ctx)
|
|
if err != nil {
|
|
return nil, err
|
|
}
|
|
return &types.QueryNextRequestIDResponse{NextRequestID: nextRequestID}, nil
|
|
}
|