Пример #1
0
 public static void Initialize()
 {
     Timer.DelayCall(TimeSpan.FromMinutes(1), TimeSpan.FromMinutes(1), () =>
     {
         Auctions.ForEach(a =>
         {
             if (a.OnGoing && a.EndTime < DateTime.Now && !a.InClaimPeriod)
             {
                 a.EndAuction();
             }
             else if (a.InClaimPeriod && DateTime.UtcNow > a.ClaimPeriod)
             {
                 a.EndClaimPeriod();
             }
         });
     });
 }