Skip to content

Commit 3d9a37e

Browse files
committed
feat(c-bridge): support for protocol upgrade when calculating dr's resolution timestamp
1 parent 9673fe1 commit 3d9a37e

File tree

3 files changed

+188
-135
lines changed

3 files changed

+188
-135
lines changed

bridges/centralized-ethereum/src/actors/dr_reporter.rs

+1-1
Original file line numberDiff line numberDiff line change
@@ -102,7 +102,7 @@ pub struct Report {
102102
/// Data Request's unique query id as known by the WitnetOracle contract
103103
pub dr_id: DrId,
104104
/// Timestamp at which the reported result was actually generated
105-
pub dr_timestamp: u64,
105+
pub dr_timestamp: i64,
106106
/// Hash of the Data Request Transaction in the Witnet blockchain
107107
pub dr_tx_hash: Hash,
108108
/// Hash of the Data Request Tally Transaction in the Witnet blockchain

bridges/centralized-ethereum/src/actors/dr_sender.rs

+1-1
Original file line numberDiff line numberDiff line change
@@ -189,7 +189,7 @@ impl DrSender {
189189

190190
dr_reporter_msgs.push(Report {
191191
dr_id,
192-
dr_timestamp: u64::from_ne_bytes(get_timestamp().to_ne_bytes()),
192+
dr_timestamp: i64::from_ne_bytes(get_timestamp().to_ne_bytes()),
193193
dr_tx_hash: zero_hash,
194194
dr_tally_tx_hash: zero_hash,
195195
result,

0 commit comments

Comments
 (0)