From 501b82b4f035d4b19eed17616484c448cbb62316 Mon Sep 17 00:00:00 2001 From: Luna Date: Sat, 8 Dec 2018 23:43:14 -0300 Subject: [PATCH] storage: fix attachment ids fetch --- litecord/storage.py | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/litecord/storage.py b/litecord/storage.py index 595b23e..a6ecbee 100644 --- a/litecord/storage.py +++ b/litecord/storage.py @@ -640,8 +640,8 @@ class Storage: async def get_attachments(self, message_id: int) -> List[Dict[str, Any]]: """Get a list of attachment objects tied to the message.""" attachment_ids = await self.db.fetch(""" - SELECT attachment_id - FROM message_attachments + SELECT id + FROM attachments WHERE message_id = $1 """, message_id)