aboutsummaryrefslogtreecommitdiff
path: root/lib/pleroma/web/chat_channel.ex
diff options
context:
space:
mode:
authorlain <lain@soykaf.club>2020-05-17 12:14:49 +0200
committerlain <lain@soykaf.club>2020-05-17 12:14:49 +0200
commit9c171097653abce49b9847fff66bc39b35719a1c (patch)
treee89ab9245f0844bfb3334f62f67f8ab9f0949580 /lib/pleroma/web/chat_channel.ex
parentf012c3a202ef43d1a8a1dc88f08057b7a41d3d78 (diff)
parentb0ccdb5af4baa119b336298d38f34746cdce0111 (diff)
downloadpleroma-9c171097653abce49b9847fff66bc39b35719a1c.tar.gz
Merge branch 'develop' of git.pleroma.social:pleroma/pleroma into remake-remodel-dms
Diffstat (limited to 'lib/pleroma/web/chat_channel.ex')
-rw-r--r--lib/pleroma/web/chat_channel.ex1
1 files changed, 1 insertions, 0 deletions
diff --git a/lib/pleroma/web/chat_channel.ex b/lib/pleroma/web/chat_channel.ex
index 38ec774f7..bce27897f 100644
--- a/lib/pleroma/web/chat_channel.ex
+++ b/lib/pleroma/web/chat_channel.ex
@@ -23,6 +23,7 @@ defmodule Pleroma.Web.ChatChannel do
if String.length(text) in 1..Pleroma.Config.get([:instance, :chat_limit]) do
author = User.get_cached_by_nickname(user_name)
author = Pleroma.Web.MastodonAPI.AccountView.render("show.json", user: author)
+
message = ChatChannelState.add_message(%{text: text, author: author})
broadcast!(socket, "new_msg", message)