Simplify log header

master
Dragory 2020-05-25 23:55:11 +03:00
parent 5c247fc73d
commit 6434066318
No known key found for this signature in database
GPG Key ID: 5F387BA66DF8AAC1
1 changed files with 1 additions and 10 deletions

View File

@ -73,16 +73,7 @@ async function serveLogs(req, res, pathParts, query) {
});
const openedAt = moment(thread.created_at).format('YYYY-MM-DD HH:mm:ss');
let header = `# ModMail thread with ${thread.user_name} (${thread.user_id}) started at ${openedAt}.`;
header += `\n# All times are in UTC+0.`;
if (! query.simple) {
header += `\n# Add ?simple=1 to the end of the log link to view only messages from the user and replies.`;
}
if (! query.verbose) {
header += `\n# Add ?verbose=1 to the end of the log link to view message IDs.`;
}
const header = `# ModMail thread with ${thread.user_name} (${thread.user_id}) started at ${openedAt}. All times are in UTC+0.`;
const fullResponse = header + '\n\n' + lines.join('\n');