Add language from activity context in ObjectValidator
Signed-off-by: marcin mikołajczak <git@mkljczk.pl>
This commit is contained in:
parent
b6bae2d319
commit
51aef6b78d
5 changed files with 54 additions and 42 deletions
|
|
@ -186,12 +186,9 @@ defmodule Pleroma.Web.ActivityPub.ObjectValidators.ArticleNotePageValidatorTest
|
|||
"actor" => user.ap_id
|
||||
}
|
||||
|
||||
{:ok, object} =
|
||||
ArticleNotePageValidator.cast_and_apply(note_activity["object"],
|
||||
activity_data: note_activity
|
||||
)
|
||||
{:ok, _create_activity, meta} = ObjectValidator.validate(note_activity, []) |> IO.inspect()
|
||||
|
||||
assert object.language == "pl"
|
||||
assert meta[:object_data]["language"] == "pl"
|
||||
end
|
||||
|
||||
test "it detects language from contentMap" do
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue