remove dead _all_formats helper, fix docstring

This commit is contained in:
esef committed 2026-07-22 19:44:32 +03:00
1 parent 4bb4fec2c5
commit ab3265667c
1 file changed
+1 -18
+1 -18
View File
@@ -2,7 +2,7 @@
######################################################################
Usage:
/timestamp → opens a popup form (day, time, country)
and returns all Discord <t:unix:FORMAT> variants.
and returns the Long Date+Time Discord <t:unix:F> tag.
"""
import calendar as cal_mod
import logging
@@ -27,23 +27,6 @@ _WEEKDAY: dict[str, int] = {
"friday": 4, "saturday": 5, "sunday": 6,
}
# ---------------------------------------------------------------------------
# helpers
# ---------------------------------------------------------------------------
def _all_formats(unix_ts: int) -> list[tuple[str, str]]:
"""Return every Discord timestamp format for *unix_ts*."""
return [
("Short Time", f"<t:{unix_ts}:t>"),
("Long Time", f"<t:{unix_ts}:T>"),
("Short Date", f"<t:{unix_ts}:d>"),
("Long Date", f"<t:{unix_ts}:D>"),
("Short Date+Time", f"<t:{unix_ts}:f>"),
("Long Date+Time", f"<t:{unix_ts}:F>"),
("Relative", f"<t:{unix_ts}:R>"),
]
# ==========================================
# MODAL
# ==========================================