• Phrodo_00@lemmy.world
    link
    fedilink
    arrow-up
    1
    ·
    8 months ago

    It depends. If something needs to happen in local time (like, always at the same time regardless of daylights savings for example) you should be storing times in local timezone

      • Phrodo_00@lemmy.world
        link
        fedilink
        arrow-up
        2
        ·
        8 months ago

        tz offset is really not enough. You’d need to save the time zone id and/or offset, to have you library calculate deviations such as daylight savings.

        Even that, that would break if the user moves and now what they setup is using their previous timezone.

        Basically, I’m saying that storing the offset works most of the time, but not all of the time.