Fix profile fields update
Signed-off-by: marcin mikołajczak <git@mkljczk.pl>
This commit is contained in:
parent
2427bf4e50
commit
44df6d547b
2 changed files with 11 additions and 11 deletions
|
@ -153,6 +153,11 @@ defmodule Pleroma.Web.ApiSpec.Schemas.Status do
|
|||
description:
|
||||
"A map consisting of alternate representations of the `content` property with the key being it's mimetype. Currently the only alternate representation supported is `text/plain`"
|
||||
},
|
||||
content_type: %Schema{
|
||||
type: :string,
|
||||
nullable: true,
|
||||
description: "A MIME type of the status"
|
||||
},
|
||||
context: %Schema{
|
||||
type: :string,
|
||||
description: "The thread identifier the status is associated with"
|
||||
|
@ -182,6 +187,11 @@ defmodule Pleroma.Web.ApiSpec.Schemas.Status do
|
|||
}
|
||||
}
|
||||
},
|
||||
event: %Schema{
|
||||
allOf: [Event],
|
||||
nullable: true,
|
||||
description: "The event attached to the status"
|
||||
},
|
||||
expires_at: %Schema{
|
||||
type: :string,
|
||||
format: "date-time",
|
||||
|
@ -241,16 +251,6 @@ defmodule Pleroma.Web.ApiSpec.Schemas.Status do
|
|||
nullable: true,
|
||||
description:
|
||||
"A datetime (ISO 8601) that states when the post was pinned or `null` if the post is not pinned"
|
||||
},
|
||||
content_type: %Schema{
|
||||
type: :string,
|
||||
nullable: true,
|
||||
description: "A MIME type of the status"
|
||||
},
|
||||
event: %Schema{
|
||||
allOf: [Event],
|
||||
nullable: true,
|
||||
description: "The event attached to the status"
|
||||
}
|
||||
}
|
||||
},
|
||||
|
|
|
@ -270,7 +270,7 @@ def update_credentials(%{assigns: %{user: user}, body_params: params} = conn, _p
|
|||
defp normalize_fields_attributes(fields) do
|
||||
if Enum.all?(fields, &is_tuple/1) do
|
||||
Enum.map(fields, fn {_, %{} = field} ->
|
||||
%{"name" => field["name"], "value" => field["value"]}
|
||||
%{"name" => field.name, "value" => field.value}
|
||||
end)
|
||||
else
|
||||
Enum.map(fields, fn
|
||||
|
|
Loading…
Reference in a new issue