Skip to content

Commit

Permalink
lockPeriod (#91)
Browse files Browse the repository at this point in the history
  • Loading branch information
gavlnxu committed Sep 6, 2023
1 parent d3204bd commit a6734d0
Showing 1 changed file with 2 additions and 1 deletion.
3 changes: 2 additions & 1 deletion pkg/client/resources.go
Original file line number Diff line number Diff line change
Expand Up @@ -105,7 +105,7 @@ func (g *GrpcClient) GetCanDelegatedMaxSize(address string, resource int32) (*ap
}

// DelegateResource from BASE58 address
func (g *GrpcClient) DelegateResource(from, to string, resource core.ResourceCode, delegateBalance int64, lock bool) (*api.TransactionExtention, error) {
func (g *GrpcClient) DelegateResource(from, to string, resource core.ResourceCode, delegateBalance int64, lock bool, lockPeriod int64) (*api.TransactionExtention, error) {
addrFromBytes, err := common.DecodeCheck(from)
if err != nil {
return nil, err
Expand All @@ -126,6 +126,7 @@ func (g *GrpcClient) DelegateResource(from, to string, resource core.ResourceCod
contract.ReceiverAddress = addrToBytes
contract.Balance = delegateBalance
contract.Lock = lock
contract.LockPeriod = lockPeriod

response, err := g.Client.DelegateResource(ctx, contract)
if err != nil {
Expand Down

0 comments on commit a6734d0

Please sign in to comment.