namespace HellionChat.Themes;

// Pure stale-check for the v1.4.8 B2 theme-auto-refresh-on-active path.
// Lives in a free helper class so the Build-Suite can exercise the diff
// rules without instantiating ThemeRegistry (which touches the Dalamud
// log proxy and the filesystem). The rules:
// - DateTime.MinValue on the current stat means we could not read the
//   file -- hold the last known good (return false).
// - Equal stamps mean no change since we last saw it.
// - Any other difference, including the first observation where lastSeen
//   is MinValue, counts as stale and triggers a reload.
internal static class ThemeStampDiff
{
    public static bool IsStale(System.DateTime lastSeen, System.DateTime current)
    {
        if (current == System.DateTime.MinValue)
            return false;
        return current != lastSeen;
    }
}
