From 9da3228251eb949c0b3acb57c2b17c21c99cf81f Mon Sep 17 00:00:00 2001 From: Sebastian Date: Thu, 17 May 2018 23:40:40 +0200 Subject: [PATCH] Warnings fixed. --- src/Squidex.Infrastructure/ValueStopwatch.cs | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/src/Squidex.Infrastructure/ValueStopwatch.cs b/src/Squidex.Infrastructure/ValueStopwatch.cs index 86c4b50c0..133cfab83 100644 --- a/src/Squidex.Infrastructure/ValueStopwatch.cs +++ b/src/Squidex.Infrastructure/ValueStopwatch.cs @@ -14,7 +14,7 @@ namespace Squidex.Infrastructure private const long TicksPerMillisecond = 10000; private const long TicksPerSecond = TicksPerMillisecond * 1000; - private static double tickFrequency; + private static readonly double TickFrequency; private readonly long startTime; @@ -22,7 +22,7 @@ namespace Squidex.Infrastructure { if (Stopwatch.IsHighResolution) { - tickFrequency = (double)TicksPerSecond / Stopwatch.Frequency; + TickFrequency = (double)TicksPerSecond / Stopwatch.Frequency; } } @@ -47,7 +47,7 @@ namespace Squidex.Infrastructure if (Stopwatch.IsHighResolution) { - elapsed = unchecked((long)(elapsed * tickFrequency)); + elapsed = unchecked((long)(elapsed * TickFrequency)); } return elapsed / TicksPerMillisecond;