Move columns found in discord api on the guilds table into redis

This commit is contained in:
Jeremy Zhang
2018-07-20 23:10:24 +00:00
parent ee051074a7
commit 3783cf1152
14 changed files with 155 additions and 158 deletions

View File

@ -100,12 +100,17 @@ def get_formatted_emojis(emojis):
})
return emotes
def get_formatted_guild(guild):
def get_formatted_guild(guild, webhooks=[]):
guil = {
"id": str(guild.id),
"name": guild.name,
"icon": guild.icon,
"icon_url": guild.icon_url,
"owner_id": guild.owner_id,
"roles": get_roles_list(guild.roles),
"channels": get_channels_list(guild.channels),
"webhooks": get_webhooks_list(webhooks),
"emojis": get_emojis_list(guild.emojis)
}
return guil