anchor.diff:  -ifdef(DECODE_TO_MAPS).
   -define(JSON_LIBS, [{jsx, 
                        fun(<<"{}">>) -> #{};
  -                        (__JS) -> maps:from_list(jsx:decode(__JS)) end,
  +                        (__JS) -> case jsx:decode(__JS) of
  +                                    [{_,_}|_]=__O -> maps:from_list(__O);
  +                                    __L when is_list(__L) -> __L end end,
                        fun(__JS) when is_list(__JS) -> jsx:encode(__JS);
                           (__JS) when is_map(__JS) -> jsx:encode(to_proplist(__JS,deep)) end},
                       {jiffy,
  
positive.code: -define(TEST_JSON, <<"{\"surname\":\"Doe\",\"name\":\"John\",\"foo\":\"bar\",\"earthling\":true,\"age\":981,\"empty\":null}">>).
  -define(TEST_PROP, [{<<"surname">>,<<"Doe">>}, {<<"name">>,<<"John">>}, {<<"foo">>,<<"bar">>}, {<<"earthling">>,true}, {<<"age">>,981},{<<"empty">>,null}]).
  -define(TEST_MAP,#{<<"age">> => 981, <<"earthling">> => true, <<"foo">> => <<"bar">>, <<"name">> => <<"John">>, <<"surname">> => <<"Doe">>,<<"empty">> => null}).
  
  %% JSON is tested for each function as well even if, basically, it only tests the 
  %% JSON to map/proplist conversion each time. This could at least be used as regression
  
negative.code: 
  -spec clean_null_values(data_object()) -> data_object().
  -ifdef(ALLOW_MAPS).
  clean_null_values([{_,_}|_] = DataObject) ->
      [{K,V} || {K,V} <- DataObject, V =/= null];
  clean_null_values(DataObject) when is_list(DataObject) ->
      DataObject;
  clean_null_values(DataObject) when is_map(DataObject) ->
      maps:fold(fun(_,null,OutMap) -> OutMap;
                   (K,V,OutMap) -> maps:put(K,V,OutMap) end,
  