mirror of
https://codeberg.org/wownero/wownero-lws
synced 2026-01-09 23:25:16 -08:00
Fix a few serialization functions
This commit is contained in:
@@ -146,14 +146,14 @@ namespace db
|
||||
void map_spend(F& format, T1& self, T2& payment_id)
|
||||
{
|
||||
wire::object(format,
|
||||
wire::field("height", self.link.height),
|
||||
wire::field("height", std::ref(self.link.height)),
|
||||
wire::field("tx_hash", std::ref(self.link.tx_hash)),
|
||||
WIRE_FIELD(image),
|
||||
WIRE_FIELD(source),
|
||||
WIRE_FIELD(timestamp),
|
||||
WIRE_FIELD(unlock_time),
|
||||
WIRE_FIELD(mixin_count),
|
||||
wire::optional_field("payment_id", payment_id)
|
||||
WIRE_FIELD(image),
|
||||
WIRE_FIELD(source),
|
||||
WIRE_FIELD(timestamp),
|
||||
WIRE_FIELD(unlock_time),
|
||||
WIRE_FIELD(mixin_count),
|
||||
wire::optional_field("payment_id", std::ref(payment_id))
|
||||
);
|
||||
}
|
||||
}
|
||||
@@ -185,8 +185,8 @@ namespace db
|
||||
{
|
||||
wire::object(format,
|
||||
wire::field("key_image", std::ref(self.value)),
|
||||
wire::field("tx_hash", std::ref(self.link.tx_hash)),
|
||||
wire::field("height", self.link.height)
|
||||
wire::field("tx_hash", std::ref(self.link.tx_hash)),
|
||||
wire::field("height", std::ref(self.link.height))
|
||||
);
|
||||
}
|
||||
}
|
||||
|
||||
@@ -85,7 +85,7 @@ namespace cryptonote
|
||||
{
|
||||
wire::object(source,
|
||||
WIRE_FIELD(amount),
|
||||
wire::variant_field("transaction output variant", std::ref(self.target),
|
||||
wire::variant_field("transaction output variant", std::ref(self.target),
|
||||
wire::option<txout_to_key>{"to_key"},
|
||||
wire::option<txout_to_script>{"to_script"},
|
||||
wire::option<txout_to_scripthash>{"to_scripthash"}
|
||||
@@ -112,7 +112,7 @@ namespace cryptonote
|
||||
static void read_bytes(wire::json_reader& source, txin_v& self)
|
||||
{
|
||||
wire::object(source,
|
||||
wire::variant_field("transaction input variant", std::ref(self),
|
||||
wire::variant_field("transaction input variant", std::ref(self),
|
||||
wire::option<txin_to_key>{"to_key"},
|
||||
wire::option<txin_gen>{"gen"},
|
||||
wire::option<txin_to_script>{"to_script"},
|
||||
|
||||
Reference in New Issue
Block a user