From 6f521043245c0e806df5b18ba1855db8f84feaa9 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Daniel=20Garc=C3=ADa?= Date: Fri, 11 Jan 2019 01:35:15 +0100 Subject: [PATCH] Fix casing error in Attachment, should fix 'Attachment doesn't exist' errors --- src/db/models/attachment.rs | 2 ++ 1 file changed, 2 insertions(+) diff --git a/src/db/models/attachment.rs b/src/db/models/attachment.rs index 82ebebd9..b86095d9 100644 --- a/src/db/models/attachment.rs +++ b/src/db/models/attachment.rs @@ -85,6 +85,8 @@ impl Attachment { } pub fn find_by_id(id: &str, conn: &DbConn) -> Option { + let id = id.to_lowercase(); + attachments::table .filter(attachments::id.eq(id)) .first::(&**conn)