Merge branch 'develop' into feature/digest-email
[akkoma] / lib / pleroma / user.ex
index cf6aee54713210b381e6832d84322b09f58d9745..c0e418e2f8c9cdd3dd9ff20e064cfad734c1935c 100644 (file)
@@ -1212,7 +1212,7 @@ defmodule Pleroma.User do
     data
     |> Map.put(:name, blank?(data[:name]) || data[:nickname])
     |> remote_user_creation()
-    |> Repo.insert(on_conflict: :replace_all, conflict_target: :nickname)
+    |> Repo.insert(on_conflict: :replace_all_except_primary_key, conflict_target: :nickname)
     |> set_cache()
   end