Skip to content
This repository has been archived by the owner on Nov 16, 2023. It is now read-only.

Commit

Permalink
fix utc/localtime mismatch
Browse files Browse the repository at this point in the history
  • Loading branch information
seanmcd-msft committed Apr 25, 2019
1 parent 11fd080 commit d73a8dc
Showing 1 changed file with 2 additions and 1 deletion.
Original file line number Diff line number Diff line change
Expand Up @@ -133,6 +133,7 @@ private Task<MethodResponse> SetFruit(MethodRequest req, Object context)
if (fruitMsg.OriginalEventUTCTime != null)
{
originalEventUTC = DateTime.Parse(fruitMsg.OriginalEventUTCTime, null, System.Globalization.DateTimeStyles.RoundtripKind);
Log.WriteLine("SetFruit invoking event. parsed msg time {0} from {1}", originalEventUTC.ToString("o"), fruitMsg.OriginalEventUTCTime);
}
if (originalEventUTC >= _lastFruitUTC)
{
Expand All @@ -152,7 +153,7 @@ private Task<MethodResponse> SetFruit(MethodRequest req, Object context)

public AzureModule()
{
_lastFruitUTC = DateTime.MinValue;
_lastFruitUTC = DateTime.SpecifyKind(DateTime.MinValue, DateTimeKind.Utc);
}
public override async Task AzureModuleInitAsync<C>(C c)
{
Expand Down

0 comments on commit d73a8dc

Please sign in to comment.