Skip to content

Commit

Permalink
Merge pull request #402 from klim0v/v1.2
Browse files Browse the repository at this point in the history
fixes
  • Loading branch information
danil-lashin authored Sep 21, 2020
2 parents 3bc1fcb + ca7d011 commit 4bd4381
Show file tree
Hide file tree
Showing 6 changed files with 7 additions and 7 deletions.
2 changes: 1 addition & 1 deletion api/v2/service/coin_info.go
Original file line number Diff line number Diff line change
Expand Up @@ -65,7 +65,7 @@ func (s *Service) CoinInfoById(ctx context.Context, req *pb.CoinIdRequest) (*pb.

coin := cState.Coins().GetCoin(types.CoinID(req.Id))
if coin == nil {
return new(pb.CoinInfoResponse), s.createError(status.New(codes.NotFound, "Coin not found"), transaction.EncodeError(transaction.EncodeError(code.NewCoinNotExists("", strconv.Itoa(int(req.Id))))))
return new(pb.CoinInfoResponse), s.createError(status.New(codes.NotFound, "Coin not found"), transaction.EncodeError(code.NewCoinNotExists("", strconv.Itoa(int(req.Id)))))
}

if timeoutStatus := s.checkTimeout(ctx); timeoutStatus != nil {
Expand Down
2 changes: 1 addition & 1 deletion api/v2/service/estimate_coin_sell_all.go
Original file line number Diff line number Diff line change
Expand Up @@ -44,7 +44,7 @@ func (s *Service) EstimateCoinSellAll(ctx context.Context, req *pb.EstimateCoinS
} else {
coinToBuy = types.CoinID(req.GetCoinIdToBuy())
if !cState.Coins().Exists(coinToBuy) {
return new(pb.EstimateCoinSellAllResponse), s.createError(status.New(codes.NotFound, "Coin to buy not exists"), transaction.EncodeError(transaction.EncodeError(code.NewCoinNotExists("", coinToBuy.String()))))
return new(pb.EstimateCoinSellAllResponse), s.createError(status.New(codes.NotFound, "Coin to buy not exists"), transaction.EncodeError(code.NewCoinNotExists("", coinToBuy.String())))
}
}

Expand Down
2 changes: 1 addition & 1 deletion api/v2/service/frozen.go
Original file line number Diff line number Diff line change
Expand Up @@ -30,7 +30,7 @@ func (s *Service) Frozen(ctx context.Context, req *pb.FrozenRequest) (*pb.Frozen
coinID := types.CoinID(req.CoinId.GetValue())
reqCoin = cState.Coins().GetCoin(coinID)
if reqCoin == nil {
return new(pb.FrozenResponse), s.createError(status.New(codes.NotFound, "Coin not found"), transaction.EncodeError(transaction.EncodeError(code.NewCoinNotExists("", coinID.String()))))
return new(pb.FrozenResponse), s.createError(status.New(codes.NotFound, "Coin not found"), transaction.EncodeError(code.NewCoinNotExists("", coinID.String())))
}
}
var frozen []*pb.FrozenResponse_Frozen
Expand Down
2 changes: 1 addition & 1 deletion core/transaction/unbond.go
Original file line number Diff line number Diff line change
Expand Up @@ -66,7 +66,7 @@ func (data UnbondData) BasicCheck(tx *Transaction, context *state.CheckState) *R
return &Response{
Code: code.StakeNotFound,
Log: fmt.Sprintf("Stake of current user not found"),
Info: EncodeError(EncodeError(code.NewStakeNotFound(data.PubKey.String(), sender.String(), data.Coin.String(), context.Coins().GetCoin(data.Coin).GetFullSymbol()))),
Info: EncodeError(code.NewStakeNotFound(data.PubKey.String(), sender.String(), data.Coin.String(), context.Coins().GetCoin(data.Coin).GetFullSymbol())),
}
}

Expand Down
2 changes: 1 addition & 1 deletion go.mod
Original file line number Diff line number Diff line change
Expand Up @@ -3,7 +3,7 @@ module github.com/MinterTeam/minter-go-node
go 1.15

require (
github.com/MinterTeam/node-grpc-gateway v1.1.3-0.20200920180544-2bc88646bf02
github.com/MinterTeam/node-grpc-gateway v1.1.3-0.20200921073010-0e0331cde460
github.com/btcsuite/btcd v0.20.1-beta
github.com/c-bata/go-prompt v0.2.3
github.com/go-kit/kit v0.10.0
Expand Down
4 changes: 2 additions & 2 deletions go.sum
Original file line number Diff line number Diff line change
Expand Up @@ -7,8 +7,8 @@ github.com/BurntSushi/xgb v0.0.0-20160522181843-27f122750802/go.mod h1:IVnqGOEym
github.com/ChainSafe/go-schnorrkel v0.0.0-20200405005733-88cbf1b4c40d h1:nalkkPQcITbvhmL4+C4cKA87NW0tfm3Kl9VXRoPywFg=
github.com/ChainSafe/go-schnorrkel v0.0.0-20200405005733-88cbf1b4c40d/go.mod h1:URdX5+vg25ts3aCh8H5IFZybJYKWhJHYMTnf+ULtoC4=
github.com/Knetic/govaluate v3.0.1-0.20171022003610-9aa49832a739+incompatible/go.mod h1:r7JcOSlj0wfOMncg0iLm8Leh48TZaKVeNIfJntJ2wa0=
github.com/MinterTeam/node-grpc-gateway v1.1.3-0.20200920180544-2bc88646bf02 h1:HJBzwDqs7xSCYRkJ6ehUJ3+ScLzFY2gg8mo3aRptsPs=
github.com/MinterTeam/node-grpc-gateway v1.1.3-0.20200920180544-2bc88646bf02/go.mod h1:LZ+Y8IYfSBx0IQZY+a9pHLjztMwmlaCQX2ncTejoE2o=
github.com/MinterTeam/node-grpc-gateway v1.1.3-0.20200921073010-0e0331cde460 h1:joYzlUOfkSr2j+jmkMxXqLF5HguzwlYx6lfJmE6/brs=
github.com/MinterTeam/node-grpc-gateway v1.1.3-0.20200921073010-0e0331cde460/go.mod h1:LZ+Y8IYfSBx0IQZY+a9pHLjztMwmlaCQX2ncTejoE2o=
github.com/OneOfOne/xxhash v1.2.2/go.mod h1:HSdplMjZKSmBqAxg5vPj2TmRDmfkzw+cTzAElWljhcU=
github.com/Shopify/sarama v1.19.0/go.mod h1:FVkBWblsNy7DGZRfXLU0O9RCGt5g3g3yEuWXgklEdEo=
github.com/Shopify/toxiproxy v2.1.4+incompatible/go.mod h1:OXgGpZ6Cli1/URJOF1DMxUHB2q5Ap20/P/eIdh4G0pI=
Expand Down

0 comments on commit 4bd4381

Please sign in to comment.