rpc/response: drop duplicating AccountState structure

This commit is contained in:
Roman Khimov 2020-02-20 12:00:20 +03:00
parent b50704fd3b
commit 465476201c

View file

@ -27,7 +27,7 @@ type InvokeResult struct {
// AccountState holds the getaccountstate response.
type AccountState struct {
Header
Result *Account `json:"result"`
Result *result.AccountState `json:"result"`
}
// Unspent represents server response to the `getunspents` command.
@ -36,22 +36,6 @@ type Unspent struct {
Result *result.Unspents `json:"result,omitempty"`
}
// Account represents details about a NEO account.
type Account struct {
Version int `json:"version"`
ScriptHash string `json:"script_hash"`
Frozen bool
// TODO: need to check this field out.
Votes []interface{}
Balances []*Balance
}
// Balance represents details about a NEO account balance.
type Balance struct {
Asset string `json:"asset"`
Value string `json:"value"`
}
// Header is a generic JSON-RPC 2.0 response header (ID and JSON-RPC version).
type Header struct {
ID json.RawMessage `json:"id"`