Actually cache the user when they're fetch from API

This commit is contained in:
thec0sm0s
2020-05-14 21:23:39 +05:30
parent 6cf7752a10
commit 2e6722e5ba

View File

@@ -110,6 +110,7 @@ class User(DiscordModelsBase):
[cls, ...] [cls, ...]
List of instances of this model when many of these models exist.""" List of instances of this model when many of these models exist."""
self = super().fetch_from_api() self = super().fetch_from_api()
app.discord.users_cache.update({self.id: self})
session["DISCORD_USER_ID"] = self.id session["DISCORD_USER_ID"] = self.id
if guilds: if guilds: