From 9dc91965b1886e813aa29f5f7fb6512e2af29858 Mon Sep 17 00:00:00 2001 From: FChannel <=> Date: Sun, 17 Jan 2021 20:45:07 -0800 Subject: support for preview images --- OutboxPost.go | 2 ++ 1 file changed, 2 insertions(+) (limited to 'OutboxPost.go') diff --git a/OutboxPost.go b/OutboxPost.go index 90c30d7..9d39eff 100644 --- a/OutboxPost.go +++ b/OutboxPost.go @@ -339,6 +339,8 @@ func ObjectFromForm(r *http.Request, db *sql.DB, obj ObjectBase) ObjectBase { fileBytes, _ := ioutil.ReadAll(file) tempFile.Write(fileBytes) + + obj.Preview = CreatePreviewObject(obj.Attachment[0]) } obj.AttributedTo = EscapeString(r.FormValue("name")) -- cgit v1.2.3