Merge branch 'oauth_consumer_support_code' into 'develop'
[akkoma] / lib / pleroma / user.ex
index 474cd8c1a1b668026271290b253713b321bdaf6b..dc534b05c1e42aa9da56abba0dcf01cdafbf1461 100644 (file)
@@ -1441,4 +1441,12 @@ defmodule Pleroma.User do
       update_and_set_cache(cng)
     end
   end
+
+  def get_ap_ids_by_nicknames(nicknames) do
+    from(u in User,
+      where: u.nickname in ^nicknames,
+      select: u.ap_id
+    )
+    |> Repo.all()
+  end
 end