projects
/
akkoma
/ commitdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
| commitdiff |
tree
raw
|
patch
| inline |
side by side
(parent:
c7140c6
)
formatter: fix matching osada users
author
William Pitcock
<nenolod@dereferenced.org>
Wed, 17 Oct 2018 19:15:20 +0000
(19:15 +0000)
committer
William Pitcock
<nenolod@dereferenced.org>
Wed, 17 Oct 2018 19:15:20 +0000
(19:15 +0000)
lib/pleroma/formatter.ex
patch
|
blob
|
history
diff --git
a/lib/pleroma/formatter.ex
b/lib/pleroma/formatter.ex
index 5b63fb795efbd2cfe4e956ed6f8cd614b99e236b..21b08a62e29b577031becbfaba24a84612cb7730 100644
(file)
--- a/
lib/pleroma/formatter.ex
+++ b/
lib/pleroma/formatter.ex
@@
-248,7
+248,12
@@
defmodule Pleroma.Formatter do
subs =
subs ++
Enum.map(mentions, fn {match, %User{ap_id: ap_id, info: info}, uuid} ->
- ap_id = info["source_data"]["url"] || ap_id
+ ap_id =
+ if is_binary(info["source_data"]["url"]) do
+ info["source_data"]["url"]
+ else
+ ap_id
+ end
short_match = String.split(match, "@") |> tl() |> hd()