fixes to compile
This commit is contained in:
parent
4503bb61f2
commit
f4c5edaca3
|
@ -150,7 +150,7 @@ func (app *Basecoin) Query(reqQuery abci.RequestQuery) (resQuery abci.ResponseQu
|
||||||
// handle special path for account info
|
// handle special path for account info
|
||||||
if reqQuery.Path == "/account" {
|
if reqQuery.Path == "/account" {
|
||||||
reqQuery.Path = "/key"
|
reqQuery.Path = "/key"
|
||||||
reqQuery.Data = sm.AccountKey(reqQuery.Data)
|
reqQuery.Data = types.AccountKey(reqQuery.Data)
|
||||||
}
|
}
|
||||||
|
|
||||||
resQuery, err := app.eyesCli.QuerySync(reqQuery)
|
resQuery, err := app.eyesCli.QuerySync(reqQuery)
|
||||||
|
|
|
@ -23,7 +23,7 @@ type AccountPresenter struct{}
|
||||||
func (_ AccountPresenter) MakeKey(str string) ([]byte, error) {
|
func (_ AccountPresenter) MakeKey(str string) ([]byte, error) {
|
||||||
res, err := hex.DecodeString(str)
|
res, err := hex.DecodeString(str)
|
||||||
if err == nil {
|
if err == nil {
|
||||||
res = state.AccountKey(res)
|
res = btypes.AccountKey(res)
|
||||||
}
|
}
|
||||||
return res, err
|
return res, err
|
||||||
}
|
}
|
||||||
|
|
|
@ -196,13 +196,18 @@ func ibcPacketCreateTxCmd(cmd *cobra.Command, args []string) error {
|
||||||
return err
|
return err
|
||||||
}
|
}
|
||||||
|
|
||||||
|
var payload ibc.Payload
|
||||||
|
if err := wire.ReadBinaryBytes(payloadBytes, &payload); err != nil {
|
||||||
|
return err
|
||||||
|
}
|
||||||
|
|
||||||
ibcTx := ibc.IBCPacketCreateTx{
|
ibcTx := ibc.IBCPacketCreateTx{
|
||||||
Packet: ibc.Packet{
|
Packet: ibc.Packet{
|
||||||
SrcChainID: fromChain,
|
SrcChainID: fromChain,
|
||||||
DstChainID: toChain,
|
DstChainID: toChain,
|
||||||
Sequence: sequence,
|
Sequence: sequence,
|
||||||
Type: packetType,
|
Type: packetType,
|
||||||
Payload: payloadBytes,
|
Payload: payload,
|
||||||
},
|
},
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
|
@ -11,7 +11,6 @@ import (
|
||||||
abci "github.com/tendermint/abci/types"
|
abci "github.com/tendermint/abci/types"
|
||||||
wire "github.com/tendermint/go-wire"
|
wire "github.com/tendermint/go-wire"
|
||||||
|
|
||||||
"github.com/tendermint/basecoin/state"
|
|
||||||
"github.com/tendermint/basecoin/types"
|
"github.com/tendermint/basecoin/types"
|
||||||
|
|
||||||
client "github.com/tendermint/tendermint/rpc/client"
|
client "github.com/tendermint/tendermint/rpc/client"
|
||||||
|
@ -114,7 +113,7 @@ func Query(tmAddr string, key []byte) (*abci.ResultQuery, error) {
|
||||||
// fetch the account by querying the app
|
// fetch the account by querying the app
|
||||||
func getAcc(tmAddr string, address []byte) (*types.Account, error) {
|
func getAcc(tmAddr string, address []byte) (*types.Account, error) {
|
||||||
|
|
||||||
key := state.AccountKey(address)
|
key := types.AccountKey(address)
|
||||||
response, err := Query(tmAddr, key)
|
response, err := Query(tmAddr, key)
|
||||||
if err != nil {
|
if err != nil {
|
||||||
return nil, err
|
return nil, err
|
||||||
|
|
Loading…
Reference in New Issue