Skip to content

Commit

Permalink
save last banner anyway just in case
Browse files Browse the repository at this point in the history
  • Loading branch information
Techbot121 authored and Meta Construct committed Jan 4, 2025
1 parent a77f568 commit 6962adc
Showing 1 changed file with 2 additions and 2 deletions.
4 changes: 2 additions & 2 deletions app/services/discord/modules/discord-events.ts
Original file line number Diff line number Diff line change
Expand Up @@ -84,11 +84,11 @@ export default (bot: DiscordBot): void => {
break;
}
}
data.lastDiscordBanner = event.guild?.bannerURL() ?? data.lastDiscordBanner;
await data.save();
const banner = event.image;
if (banner) {
data.lastDiscordBanner = event.guild?.bannerURL() ?? data.lastDiscordBanner;
await event.guild?.setBanner(banner, "Event banner");
await data.save();
}
break;
}
Expand Down

0 comments on commit 6962adc

Please sign in to comment.