mirror of
https://github.com/ZeppelinBot/Zeppelin.git
synced 2025-05-18 07:35:02 +00:00
Add GuildArchives.getUrl for getting the archive entry URL
This commit is contained in:
parent
6f48ba932f
commit
0558fc7ab2
3 changed files with 9 additions and 5 deletions
|
@ -341,14 +341,14 @@ export class LogsPlugin extends Plugin {
|
|||
async onMessageDeleteBulk(savedMessages: SavedMessage[]) {
|
||||
const channel = this.guild.channels.get(savedMessages[0].channel_id);
|
||||
const archiveId = await this.archives.createFromSavedMessages(savedMessages, this.guild);
|
||||
const baseUrl = this.knub.getGlobalConfig().url;
|
||||
const archiveUrl = this.archives.getUrl(this.knub.getGlobalConfig().url, archiveId);
|
||||
|
||||
this.guildLogs.log(
|
||||
LogType.MESSAGE_DELETE_BULK,
|
||||
{
|
||||
count: savedMessages.length,
|
||||
channel,
|
||||
archiveUrl: `${baseUrl}/archives/${archiveId}`
|
||||
archiveUrl
|
||||
},
|
||||
savedMessages[0].id
|
||||
);
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue