From 54650161b9d421498b9b34714ef20d93f3cfa7f2 Mon Sep 17 00:00:00 2001 From: Luna Date: Sat, 8 Dec 2018 23:39:56 -0300 Subject: [PATCH] storage: fix attachment.url --- litecord/storage.py | 4 +--- 1 file changed, 1 insertion(+), 3 deletions(-) diff --git a/litecord/storage.py b/litecord/storage.py index 66629c2..595b23e 100644 --- a/litecord/storage.py +++ b/litecord/storage.py @@ -668,11 +668,9 @@ class Storage: proto = 'https' if self.app.config['IS_SSL'] else 'http' main_url = self.app.config['MAIN_URL'] - attachment_ext = get_ext(row['mime']) - drow['url'] = (f'{proto}://{main_url}/attachments/' f'{row["channel_id"]}/{row["message_id"]}/' - f'{row["filename"]}.{attachment_ext}') + f'{row["filename"]}') # NOTE: since the url comes from the instance itself # i think proxy_url=url is valid.