3
0
Fork 0
mirror of https://github.com/ZeppelinBot/Zeppelin.git synced 2025-05-10 12:25:02 +00:00

feat: move log timestamp prepending to log message format; use native timestamps by default

This commit is contained in:
Dragory 2021-11-02 21:27:08 +02:00
parent 9105495d72
commit 4179bc4ee1
No known key found for this signature in database
GPG key ID: 5F387BA66DF8AAC1
3 changed files with 73 additions and 76 deletions

View file

@ -123,7 +123,7 @@ const defaultOptions: PluginOptions<LogsPluginType> = {
},
ping_user: true, // Legacy/deprecated, if below is false mentions wont actually ping. In case you really want the old behavior, set below to true
allow_user_mentions: false,
timestamp_format: "YYYY-MM-DD HH:mm:ss z",
timestamp_format: "[<t:]X[>]",
include_embed_timestamp: true,
},

View file

@ -131,9 +131,6 @@ export async function getLogMessage<TLogType extends keyof ILogTypeData>(
if (typeof formatted === "string") {
formatted = formatted.trim();
if (timestamp) {
formatted = `\`[${timestamp}]\` ${formatted}`;
}
} else if (formatted != null) {
formatted = validateAndParseMessageContent(formatted);