Hardcode kiribati date shift offset

Should have been "UTC+12"
We can just inline the shifting since it'll always add 12 hours to the current UTC time, thus that's the maximum date value possible
This commit is contained in:
Kurt 2021-10-01 08:35:11 -07:00
parent 6deef4e76d
commit 015afdf369

View File

@ -71,8 +71,7 @@ public bool IsWithinStartEnd(int stamp)
/// </summary>
public static int GetTimeStamp(int year, int month, int day) => (year << 16) | (month << 8) | day;
private static readonly TimeZoneInfo Kiribati = TimeZoneInfo.FindSystemTimeZoneById("KI");
private static DateTime GetMaxDateTime() => TimeZoneInfo.ConvertTimeFromUtc(DateTime.UtcNow, Kiribati);
private static DateTime GetMaxDateTime() => DateTime.UtcNow.AddHours(12); // UTC+12 for Kiribati, no daylight savings
/// <summary>
/// Gets a random date within the availability range.