Commit 97b35e00 authored by 0x1C3B00DA's avatar 0x1C3B00DA

Fix with expression always matching

parent e572786d
......@@ -1167,9 +1167,7 @@ defmodule Pleroma.User do
if !is_nil(user) and !User.needs_update?(user) do
{:ok, user}
else
user = fetch_by_ap_id(ap_id)
with %User{} = user do
with %User{} = user <- fetch_by_ap_id(ap_id) do
if Pleroma.Config.get([:fetch_initial_posts, :enabled]) do
{:ok, _} = Task.start(__MODULE__, :fetch_initial_posts, [user])
end
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment