aboutsummaryrefslogtreecommitdiff
path: root/appservice/account.go
diff options
context:
space:
mode:
Diffstat (limited to 'appservice/account.go')
-rw-r--r--appservice/account.go18
1 files changed, 9 insertions, 9 deletions
diff --git a/appservice/account.go b/appservice/account.go
index f1f9d13..4bb2dfe 100644
--- a/appservice/account.go
+++ b/appservice/account.go
@@ -286,24 +286,24 @@ func (a *Account) eventInternal(event *Event) error {
if err != nil {
return err
}
- content := map[string]interface{} {
- "body": mxfile.Filename(),
+ content := map[string]interface{}{
+ "body": mxfile.Filename(),
"filename": mxfile.Filename(),
- "url": fmt.Sprintf("mxc://%s/%s", mxfile.MxcServer, mxfile.MxcMediaId),
+ "url": fmt.Sprintf("mxc://%s/%s", mxfile.MxcServer, mxfile.MxcMediaId),
}
if sz := mxfile.ImageSize(); sz != nil {
content["msgtype"] = "m.image"
- content["info"] = map[string]interface{} {
+ content["info"] = map[string]interface{}{
"mimetype": mxfile.Mimetype(),
- "size": mxfile.Size(),
- "w": sz.Width,
- "h": sz.Height,
+ "size": mxfile.Size(),
+ "w": sz.Width,
+ "h": sz.Height,
}
} else {
content["msgtype"] = "m.file"
- content["info"] = map[string]interface{} {
+ content["info"] = map[string]interface{}{
"mimetype": mxfile.Mimetype(),
- "size": mxfile.Size(),
+ "size": mxfile.Size(),
}
}
err = mx.SendAs(mx_room_id, "m.room.message", content, mx_user_id)