Prefer ids to usernames
authorrinpatch <rinpatch@sdf.org>
Mon, 14 Jan 2019 06:52:52 +0000 (09:52 +0300)
committerrinpatch <rinpatch@sdf.org>
Mon, 14 Jan 2019 06:52:52 +0000 (09:52 +0300)
lib/pleroma/user.ex

index 3120b13b63bd5018523f42c4fbe0712cdb345cbb..26cef53ee6f1b64679c93f5fecdfee84a2d26093 100644 (file)
@@ -454,7 +454,7 @@ defmodule Pleroma.User do
   end
 
   def get_cached_by_nickname_or_id(nickname_or_id) do
-    get_cached_by_nickname(nickname_or_id) || get_cached_by_id(nickname_or_id)
+    get_cached_by_id(nickname_or_id) || get_cached_by_nickname(nickname_or_id) 
   end
 
   def get_by_nickname(nickname) do