Skip to content

Commit

Permalink
feat(c-bridge): support for protocol upgrade when calculating dr's re…
Browse files Browse the repository at this point in the history
…solution timestamp
  • Loading branch information
guidiaz committed Dec 12, 2024
1 parent 753eb88 commit 7d4fb36
Show file tree
Hide file tree
Showing 3 changed files with 188 additions and 135 deletions.
2 changes: 1 addition & 1 deletion bridges/centralized-ethereum/src/actors/dr_reporter.rs
Original file line number Diff line number Diff line change
Expand Up @@ -102,7 +102,7 @@ pub struct Report {
/// Data Request's unique query id as known by the WitnetOracle contract
pub dr_id: DrId,
/// Timestamp at which the reported result was actually generated
pub dr_timestamp: u64,
pub dr_timestamp: i64,
/// Hash of the Data Request Transaction in the Witnet blockchain
pub dr_tx_hash: Hash,
/// Hash of the Data Request Tally Transaction in the Witnet blockchain
Expand Down
2 changes: 1 addition & 1 deletion bridges/centralized-ethereum/src/actors/dr_sender.rs
Original file line number Diff line number Diff line change
Expand Up @@ -189,7 +189,7 @@ impl DrSender {

dr_reporter_msgs.push(Report {
dr_id,
dr_timestamp: u64::from_ne_bytes(get_timestamp().to_ne_bytes()),
dr_timestamp: i64::from_ne_bytes(get_timestamp().to_ne_bytes()),
dr_tx_hash: zero_hash,
dr_tally_tx_hash: zero_hash,
result,
Expand Down
Loading

0 comments on commit 7d4fb36

Please sign in to comment.