summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorGuillaume <guillaumelacasa@hotmail.com>2013-06-13 20:34:57 +0200
committerGuillaume <guillaumelacasa@hotmail.com>2013-06-13 20:34:57 +0200
commitff46be4aa905588089b25b2cefe242eac0af7c6c (patch)
tree13f0f150ce9eb0a298d8195a41760e4f05e3646d
parent549ea802b7fe5dd69c8f7d62cfd7823c9475b3b4 (diff)
downloadTwoStepsAuthenticator-ff46be4aa905588089b25b2cefe242eac0af7c6c.zip
TwoStepsAuthenticator-ff46be4aa905588089b25b2cefe242eac0af7c6c.tar.gz
TwoStepsAuthenticator-ff46be4aa905588089b25b2cefe242eac0af7c6c.tar.bz2
Test values removed.
-rw-r--r--TwoStepsAuthenticator/UsedCodesManager.cs4
1 files changed, 2 insertions, 2 deletions
diff --git a/TwoStepsAuthenticator/UsedCodesManager.cs b/TwoStepsAuthenticator/UsedCodesManager.cs
index d60e1cb..3d4247b 100644
--- a/TwoStepsAuthenticator/UsedCodesManager.cs
+++ b/TwoStepsAuthenticator/UsedCodesManager.cs
@@ -41,14 +41,14 @@ namespace TwoStepsAuthenticator
public UsedCodesManager()
{
codes = new Queue<UsedCode>();
- cleaner = new Timer(TimeSpan.FromSeconds(5).TotalMilliseconds);
+ cleaner = new Timer(TimeSpan.FromMinutes(5).TotalMilliseconds);
cleaner.Elapsed += cleaner_Elapsed;
cleaner.Start();
}
void cleaner_Elapsed(object sender, ElapsedEventArgs e)
{
- var timeToClean = DateTime.Now.AddSeconds(-5);
+ var timeToClean = DateTime.Now.AddMinutes(-5);
lock (codeLock)
{
while (codes.Count > 0 && codes.Peek().UseDate < timeToClean)