MCPcopy Index your code
hub / github.com/CovenantSQL/CovenantSQL / getNonce

Function getNonce

client/driver.go:512–523  ·  view source on GitHub ↗
(addr proto.AccountAddress)

Source from the content-addressed store, hash-verified

510}
511
512func getNonce(addr proto.AccountAddress) (nonce interfaces.AccountNonce, err error) {
513 nonceReq := new(types.NextAccountNonceReq)
514 nonceResp := new(types.NextAccountNonceResp)
515 nonceReq.Addr = addr
516 err = requestBP(route.MCCNextAccountNonce, nonceReq, nonceResp)
517 if err != nil {
518 log.WithError(err).Warning("get nonce failed")
519 return
520 }
521 nonce = nonceResp.Nonce
522 return
523}
524
525func requestBP(method route.RemoteFunc, request interface{}, response interface{}) (err error) {
526 var bpNodeID proto.NodeID

Callers 2

UpdatePermissionFunction · 0.85
TransferTokenFunction · 0.85

Calls 3

WithErrorFunction · 0.92
requestBPFunction · 0.85
WarningMethod · 0.80

Tested by

no test coverage detected