diff options
author | lain <lain@soykaf.club> | 2018-02-18 23:11:31 +0100 |
---|---|---|
committer | lain <lain@soykaf.club> | 2018-02-18 23:11:31 +0100 |
commit | 8b1154633430d2f2c0cb7375bec66cf7f0f35583 (patch) | |
tree | d307ae472dd8c11e36b0037a845334e7d58aea27 | |
parent | decbf3a47fbcaea9ebc6b5ab9348260289100faf (diff) | |
download | pleroma-8b1154633430d2f2c0cb7375bec66cf7f0f35583.tar.gz |
For existing users, just replace info.
-rw-r--r-- | lib/pleroma/web/activity_pub/activity_pub.ex | 6 |
1 files changed, 6 insertions, 0 deletions
diff --git a/lib/pleroma/web/activity_pub/activity_pub.ex b/lib/pleroma/web/activity_pub/activity_pub.ex index a0d36d03a..4e46e80ea 100644 --- a/lib/pleroma/web/activity_pub/activity_pub.ex +++ b/lib/pleroma/web/activity_pub/activity_pub.ex @@ -273,6 +273,12 @@ defmodule Pleroma.Web.ActivityPub.ActivityPub do } User.insert_or_update_user(user_data) + if user = User.get_by_ap_id(ap_id) do + User.info_changeset(user, user_data} + |> Repo.update + else + User.insert_or_update_user(user_data) + end end end |