Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Fd 1247 #131

Merged
merged 1 commit into from
Nov 13, 2019
Merged
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
19 changes: 11 additions & 8 deletions fblock.go
Original file line number Diff line number Diff line change
Expand Up @@ -14,13 +14,16 @@ import (
// Note: the FBlock api return does not use a "Header" field like the other
// block types do for some reason.
type FBlock struct {
BodyMR string `json:"bodymr"` // Merkle root of the Factoid transactions which accompany this block.
PrevKeyMR string `json:"prevkeymr"` // Key Merkle root of previous block.
PrevLedgerKeyMR string `json:"prevledgerkeymr"` // Sha3 of the previous Factoid Block
ExchRate int64 `json:"exchrate"` // Factoshis per Entry Credit
DBHeight int64 `json:"dbheight"` // Directory Block height

Transactions []Transaction `json:"transactions"`
BodyMR string `json:"bodymr"` // Merkle root of the Factoid transactions which accompany this block.
PrevKeyMR string `json:"prevkeymr"` // Key Merkle root of previous block.
PrevLedgerKeyMR string `json:"prevledgerkeymr"` // Sha3 of the previous Factoid Block
ExchRate int64 `json:"exchrate"` // Factoshis per Entry Credit
DBHeight int64 `json:"dbheight"` // Directory Block height
Transactions []json.RawMessage `json:"transactions"`

ChainID string `json:"chainid,omitempty"`
KeyMR string `json:"keymr,omitempty"`
LedgerKeyMR string `json:"ledgerkeymr,omitempty"`
}

func (f *FBlock) String() string {
Expand All @@ -34,7 +37,7 @@ func (f *FBlock) String() string {

s += fmt.Sprintln("Transactions {")
for _, t := range f.Transactions {
s += fmt.Sprintln(t)
s += fmt.Sprintln(string(t))
}
s += fmt.Sprintln("}")

Expand Down