File tree 1 file changed +4
-14
lines changed
src/Microsoft.AspNetCore.Server.Kestrel/Http 1 file changed +4
-14
lines changed Original file line number Diff line number Diff line change @@ -58,9 +58,11 @@ internal DateHeaderValueManager(
58
58
/// <returns>The value in string and byte[] format.</returns>
59
59
public DateHeaderValues GetDateHeaderValues ( )
60
60
{
61
- if ( ! _hadRequestsSinceLastTimerTick )
61
+ _hadRequestsSinceLastTimerTick = ! _isDisposed ;
62
+
63
+ if ( ! _timerIsRunning )
62
64
{
63
- PrepareDateValues ( ) ;
65
+ StartTimer ( ) ;
64
66
}
65
67
66
68
return _dateValues ;
@@ -151,18 +153,6 @@ private void TimerLoop(object state)
151
153
}
152
154
}
153
155
154
- /// <summary>
155
- /// Starts the timer if it's turned off, or sets the datevalues to the current time if disposed.
156
- /// </summary>
157
- private void PrepareDateValues ( )
158
- {
159
- _hadRequestsSinceLastTimerTick = ! _isDisposed ;
160
- if ( ! _timerIsRunning )
161
- {
162
- StartTimer ( ) ;
163
- }
164
- }
165
-
166
156
/// <summary>
167
157
/// Sets date values from a provided ticks value
168
158
/// </summary>
You can’t perform that action at this time.
0 commit comments