aboutsummaryrefslogtreecommitdiff
path: root/OutboxPost.go
diff options
context:
space:
mode:
authorFChannel <=>2021-01-17 20:45:07 -0800
committerFChannel <=>2021-01-17 20:45:07 -0800
commit9dc91965b1886e813aa29f5f7fb6512e2af29858 (patch)
tree14f80f35b7e6cfba1471e213ce9fd62dc97961e6 /OutboxPost.go
parent89f88072c9ffd6a6e321ee7b5455665d82dbd6d7 (diff)
support for preview images
Diffstat (limited to 'OutboxPost.go')
-rw-r--r--OutboxPost.go2
1 files changed, 2 insertions, 0 deletions
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"))