value -> {:ok, value}
end
+ status_ttl_days_value = fn
+ -1 -> {:ok, nil}
+ value -> {:ok, value}
+ end
+
user_params =
[
:no_rich_text,
# Note: param name is indeed :discoverable (not an error)
|> Maps.put_if_present(:is_discoverable, params[:discoverable])
|> Maps.put_if_present(:language, Pleroma.Web.Gettext.normalize_locale(params[:language]))
+ |> Maps.put_if_present(:status_ttl_days, params[:status_ttl_days], status_ttl_days_value)
+ IO.inspect(user_params)
# What happens here:
#
# We want to update the user through the pipeline, but the ActivityPub