Skip to content

Commit

Permalink
Merge pull request #168 from Nitrokey/improveOTPdisplay
Browse files Browse the repository at this point in the history
fix timeout UI OTP
  • Loading branch information
daringer authored Nov 21, 2023
2 parents 3e59d1f + ec6ca37 commit d73eaa6
Showing 1 changed file with 2 additions and 2 deletions.
4 changes: 2 additions & 2 deletions nitrokeyapp/secrets_tab/__init__.py
Original file line number Diff line number Diff line change
Expand Up @@ -178,9 +178,9 @@ def otp_generated(self, data: OtpData) -> None:
if data.validity:
start, end = data.validity
period = int((end - start).total_seconds())
self.ui.progressBarOtpTimeout.setMaximum(period)
self.ui.progressBarOtpTimeout.setMaximum(period + period)

self.otp_timeout = end
self.otp_timeout = end + (end - start)
self.otp_timer.start()
self.update_otp_timeout()

Expand Down

0 comments on commit d73eaa6

Please sign in to comment.