mirror of
https://github.com/legop3/MultiRoombaRover.git
synced 2026-09-16 09:31:20 -04:00
whue
This commit is contained in:
@@ -25,7 +25,23 @@ function createTimeStatusCommand({ config, discordConfig }) {
|
||||
return async function handleTimeStatusCommand(message) {
|
||||
const serverTimezone = getServerTimezone();
|
||||
const now = new Date();
|
||||
const zones = ['UTC', 'America/Los_Angeles', 'America/Denver', 'America/Chicago', 'America/New_York'];
|
||||
const zones = [
|
||||
'UTC',
|
||||
'America/Los_Angeles',
|
||||
'America/Denver',
|
||||
'America/Chicago',
|
||||
'America/New_York',
|
||||
'America/Halifax',
|
||||
'Pacific/Honolulu',
|
||||
'Europe/London',
|
||||
'Europe/Berlin',
|
||||
'Asia/Tokyo',
|
||||
'Australia/Sydney',
|
||||
'Pacific/Auckland',
|
||||
];
|
||||
if (!zones.includes(serverTimezone)) {
|
||||
zones.push(serverTimezone);
|
||||
}
|
||||
const lines = zones.map((zone) => `${zone} — ${formatTimeInZone(now, zone)}${zone === serverTimezone ? ' **(server local timezone)**' : ''}`);
|
||||
const embed = buildEmbed({ title: 'Time Status', description: lines.join('\n'), color: 0x2196f3 });
|
||||
embed.setFooter({ text: `Server local timezone: ${serverTimezone}` });
|
||||
|
||||
Reference in New Issue
Block a user