Skip to content
GitLab
Menu
Projects
Groups
Snippets
/
Help
Help
Support
Community forum
Keyboard shortcuts
?
Submit feedback
Contribute to GitLab
Sign in / Register
Toggle navigation
Menu
Open sidebar
Pleroma
pleroma
Commits
1dba3bc4
Commit
1dba3bc4
authored
Jan 23, 2022
by
marcin mikołajczak
Browse files
Preserve order of mentioned users
Signed-off-by:
marcin mikołajczak
<
git@mkljczk.pl
>
parent
9983799c
Changes
1
Hide whitespace changes
Inline
Side-by-side
lib/pleroma/user.ex
View file @
1dba3bc4
...
...
@@ -2279,6 +2279,7 @@ def ensure_keys_present(%User{} = user) do
def
get_ap_ids_by_nicknames
(
nicknames
)
do
from
(
u
in
User
,
where:
u
.
nickname
in
^
nicknames
,
order_by:
fragment
(
"array_position(?, ?)"
,
^
nicknames
,
u
.
nickname
),
select:
u
.
ap_id
)
|>
Repo
.
all
()
...
...
Write
Preview
Supports
Markdown
0%
Try again
or
attach a new file
.
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment