Commit 489e238
authored
fix: Return current timestamp when nonce lags (#108)
The function `next_nonce()` always returns a unique nonce, by storing
the current timestamp in a static variable and incrementing it before
returning. However, this variable can lag during times of inactivity.
Though there is a check that handles it by updating it with the current
timestamp, it ends with returning the old nonce, which fails the current
call.
This fix makes sure that the current timestamp is returned when this
check gets triggered.1 parent ae36ca5 commit 489e238
1 file changed
+2
-1
lines changed| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
19 | 19 | | |
20 | 20 | | |
21 | 21 | | |
22 | | - | |
| 22 | + | |
| 23 | + | |
23 | 24 | | |
24 | 25 | | |
25 | 26 | | |
| |||
0 commit comments