diff options
author | lain <lain@soykaf.club> | 2020-05-05 20:07:47 +0200 |
---|---|---|
committer | lain <lain@soykaf.club> | 2020-05-05 20:07:47 +0200 |
commit | 9637cded21cef1e6c531dd46d5f5245c4c3ed03c (patch) | |
tree | c06f9fcd0626bcc13e2886f2e41a6871cebc8cdd /lib | |
parent | c23cb8d37a44e4b9ff09655e452122235ded1d84 (diff) | |
download | pleroma-9637cded21cef1e6c531dd46d5f5245c4c3ed03c.tar.gz |
Chat: Fix missing chat id on second 'get'
Diffstat (limited to 'lib')
-rw-r--r-- | lib/pleroma/chat.ex | 3 |
1 files changed, 2 insertions, 1 deletions
diff --git a/lib/pleroma/chat.ex b/lib/pleroma/chat.ex index 6008196e4..1a092b992 100644 --- a/lib/pleroma/chat.ex +++ b/lib/pleroma/chat.ex @@ -46,7 +46,8 @@ defmodule Pleroma.Chat do %__MODULE__{} |> creation_cng(%{user_id: user_id, recipient: recipient}) |> Repo.insert( - on_conflict: :nothing, + # Need to set something, otherwise we get nothing back at all + on_conflict: [set: [recipient: recipient]], returning: true, conflict_target: [:user_id, :recipient] ) |