diff --git a/util/btcctl/btcctl.go b/util/btcctl/btcctl.go index 71e143c4..b34940bd 100644 --- a/util/btcctl/btcctl.go +++ b/util/btcctl/btcctl.go @@ -49,6 +49,7 @@ var commandHandlers = map[string]*handlerData{ "decoderawtransaction": &handlerData{1, 0, displayJSONDump, nil, makeDecodeRawTransaction, ""}, "dumpprivkey": &handlerData{1, 0, displayGeneric, nil, makeDumpPrivKey, ""}, "getaccount": &handlerData{1, 0, displayGeneric, nil, makeGetAccount, "
"}, + "getaccountaddress": &handlerData{1, 0, displayGeneric, nil, makeGetAccountAddress, ""}, "getbalance": &handlerData{0, 2, displayGeneric, []conversionHandler{nil, toInt}, makeGetBalance, "[account] [minconf=1]"}, "getbestblockhash": &handlerData{0, 0, displayGeneric, nil, makeGetBestBlockHash, ""}, "getblock": &handlerData{1, 2, displayJSONDump, []conversionHandler{nil, toBool, toBool}, makeGetBlock, ""}, @@ -173,6 +174,12 @@ func makeGetAccount(args []interface{}) (btcjson.Cmd, error) { return btcjson.NewGetAccountCmd("btcctl", args[0].(string)) } +// makeGetAccountAddress generates the cmd structure for +// getaccountaddress commands. +func makeGetAccountAddress(args []interface{}) (btcjson.Cmd, error) { + return btcjson.NewGetAccountAddressCmd("btcctl", args[0].(string)) +} + // makeGetBalance generates the cmd structure for // getbalance commands. func makeGetBalance(args []interface{}) (btcjson.Cmd, error) {