Commit d487b753 authored by kaniini's avatar kaniini
Browse files

activitypub: transmogrifier: do not allow missing lists to be interpreted as nil

parent 798da288
......@@ -86,11 +86,15 @@ def fix_object(object) do
end
def fix_addressing_list(map, field) do
if is_binary(map[field]) do
map
|> Map.put(field, [map[field]])
else
map
cond do
is_binary(map[field]) ->
Map.put(map, field, [map[field]])
is_nil(map[field]) ->
Map.put(map, field, [])
true ->
map
end
end
......
Supports Markdown
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