Use async flag directly from context

This commit is contained in:
ValarDragon
2018-07-05 20:15:40 -07:00
parent 27a31cae44
commit 8857b69d02
9 changed files with 18 additions and 18 deletions
+2 -2
View File
@@ -35,7 +35,7 @@ func QuizTxCmd(cdc *wire.Codec) *cobra.Command {
name := viper.GetString(client.FlagName)
// build and sign the transaction, then broadcast to Tendermint
err = ctx.EnsureSignBuildBroadcast(name, []sdk.Msg{msg}, cdc, ctx.Async, false)
err = ctx.EnsureSignBuildBroadcast(name, []sdk.Msg{msg}, cdc, false)
if err != nil {
return err
}
@@ -67,7 +67,7 @@ func SetTrendTxCmd(cdc *wire.Codec) *cobra.Command {
msg := cool.NewMsgSetTrend(from, args[0])
// build and sign the transaction, then broadcast to Tendermint
err = ctx.EnsureSignBuildBroadcast(name, []sdk.Msg{msg}, cdc, ctx.Async, false)
err = ctx.EnsureSignBuildBroadcast(name, []sdk.Msg{msg}, cdc, false)
if err != nil {
return err
}
+1 -1
View File
@@ -48,7 +48,7 @@ func MineCmd(cdc *wire.Codec) *cobra.Command {
name := ctx.FromAddressName
// build and sign the transaction, then broadcast to Tendermint
err = ctx.EnsureSignBuildBroadcast(name, []sdk.Msg{msg}, cdc, ctx.Async, false)
err = ctx.EnsureSignBuildBroadcast(name, []sdk.Msg{msg}, cdc, false)
if err != nil {
return err
}
@@ -87,7 +87,7 @@ func UnbondTxCmd(cdc *wire.Codec) *cobra.Command {
func sendMsg(cdc *wire.Codec, msg sdk.Msg) error {
ctx := context.NewCoreContextFromViper().WithDecoder(authcmd.GetAccountDecoder(cdc))
err := ctx.EnsureSignBuildBroadcast(ctx.FromAddressName, []sdk.Msg{msg}, cdc, ctx.Async, false)
err := ctx.EnsureSignBuildBroadcast(ctx.FromAddressName, []sdk.Msg{msg}, cdc, false)
if err != nil {
return err
}