Skip to content

Commit ae77ba3

Browse files
committed
fix(chain-1993): align eip1559 windows
1 parent 7b8603f commit ae77ba3

2 files changed

Lines changed: 4 additions & 2 deletions

File tree

solana/programs/base_relayer/src/internal/eip_1559.rs

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -69,7 +69,8 @@ impl Eip1559 {
6969
// Update state for new window
7070
self.current_base_fee = current_base_fee;
7171
self.current_window_gas_used = 0;
72-
self.window_start_time = current_timestamp;
72+
self.window_start_time +=
73+
(expired_windows_count * self.config.window_duration_seconds) as i64;
7374

7475
current_base_fee
7576
}

solana/programs/bridge/src/common/state/bridge.rs

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -101,7 +101,8 @@ impl Eip1559 {
101101
// Update state for new window
102102
self.current_base_fee = current_base_fee;
103103
self.current_window_gas_used = 0;
104-
self.window_start_time = current_timestamp;
104+
self.window_start_time +=
105+
(expired_windows_count * self.config.window_duration_seconds) as i64;
105106

106107
current_base_fee
107108
}

0 commit comments

Comments
 (0)