projects
/
akkoma
/ commitdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
| commitdiff |
tree
raw
|
patch
| inline |
side by side
(parent:
1e88f10
)
Quick fix for activities without 'to'.
author
Roger Braun
<roger@rogerbraun.net>
Thu, 20 Apr 2017 23:01:58 +0000
(
01:01
+0200)
committer
Roger Braun
<roger@rogerbraun.net>
Thu, 20 Apr 2017 23:01:58 +0000
(
01:01
+0200)
lib/pleroma/web/twitter_api/twitter_api.ex
patch
|
blob
|
history
diff --git
a/lib/pleroma/web/twitter_api/twitter_api.ex
b/lib/pleroma/web/twitter_api/twitter_api.ex
index ce29d46a1420add15ca6f0d965c99545c08b4634..1053120c4f50a3b5c64db933149c2c3d211c5699 100644
(file)
--- a/
lib/pleroma/web/twitter_api/twitter_api.ex
+++ b/
lib/pleroma/web/twitter_api/twitter_api.ex
@@
-318,7
+318,7
@@
defmodule Pleroma.Web.TwitterAPI.TwitterAPI do
actor = get_in(activity.data, ["actor"])
user = User.get_cached_by_ap_id(actor)
# mentioned_users = Repo.all(from user in User, where: user.ap_id in ^activity.data["to"])
- mentioned_users = Enum.map(activity.data["to"], fn (ap_id) ->
+ mentioned_users = Enum.map(activity.data["to"]
|| []
, fn (ap_id) ->
User.get_cached_by_ap_id(ap_id)
end)
|> Enum.filter(&(&1))