statevminternal circ supply
This commit is contained in:
parent
8351420404
commit
af1a422ddd
@ -56,6 +56,7 @@ type gatewayDepsAPI interface {
|
|||||||
StateMinerAvailableBalance(context.Context, address.Address, types.TipSetKey) (types.BigInt, error)
|
StateMinerAvailableBalance(context.Context, address.Address, types.TipSetKey) (types.BigInt, error)
|
||||||
StateMinerProvingDeadline(context.Context, address.Address, types.TipSetKey) (*dline.Info, error)
|
StateMinerProvingDeadline(context.Context, address.Address, types.TipSetKey) (*dline.Info, error)
|
||||||
StateCirculatingSupply(context.Context, types.TipSetKey) (abi.TokenAmount, error)
|
StateCirculatingSupply(context.Context, types.TipSetKey) (abi.TokenAmount, error)
|
||||||
|
StateVMCirculatingSupplyInternal(context.Context, types.TipSetKey) (api.CirculatingSupply, error)
|
||||||
}
|
}
|
||||||
|
|
||||||
type GatewayAPI struct {
|
type GatewayAPI struct {
|
||||||
@ -277,6 +278,13 @@ func (a *GatewayAPI) StateCirculatingSupply(ctx context.Context, tsk types.TipSe
|
|||||||
|
|
||||||
}
|
}
|
||||||
|
|
||||||
|
func (a *GatewayAPI) StateVMCirculatingSupplyInternal(ctx context.Context, tsk types.TipSetKey) (api.CirculatingSupply, error) {
|
||||||
|
if err := a.checkTipsetKey(ctx, tsk); err != nil {
|
||||||
|
return api.CirculatingSupply{}, err
|
||||||
|
}
|
||||||
|
return a.api.StateVMCirculatingSupplyInternal(ctx, tsk)
|
||||||
|
}
|
||||||
|
|
||||||
func (a *GatewayAPI) WalletVerify(ctx context.Context, k address.Address, msg []byte, sig *crypto.Signature) (bool, error) {
|
func (a *GatewayAPI) WalletVerify(ctx context.Context, k address.Address, msg []byte, sig *crypto.Signature) (bool, error) {
|
||||||
return sigs.Verify(sig, k, msg) == nil, nil
|
return sigs.Verify(sig, k, msg) == nil, nil
|
||||||
}
|
}
|
||||||
|
Loading…
Reference in New Issue
Block a user