There should be a guard `is_list(Dict)` in the last clause to avoid failing with `badarg` instead of `function_clause`.