fix(economy): Refresh stale balance data.

This commit is contained in:
2023-09-10 14:38:04 +03:00
parent d21d734c0d
commit f59f3093d8
2 changed files with 3 additions and 1 deletions

View File

@@ -85,6 +85,8 @@ class LionMember(Timezoned):
"""
if member.display_name != self.data.display_name:
await self.data.update(display_name=member.display_name)
else:
await self.data.refresh()
async def fetch_member(self) -> Optional[discord.Member]:
"""

View File

@@ -476,7 +476,7 @@ class Economy(LionCog):
else:
# If we have a single target, show their current balance, with a short transaction history.
user = targets[0]
row = await self.bot.core.data.Member.fetch(ctx.guild.id, user.id)
row = await self.bot.core.data.Member.fetch(ctx.guild.id, user.id, cached=False)
embed = discord.Embed(
colour=discord.Colour.orange(),