(dictionary)
| 44 | |
| 45 | |
| 46 | def _underscore_dict(dictionary): |
| 47 | new_dictionary = {} |
| 48 | for key, value in dictionary.items(): |
| 49 | if isinstance(value, dict): |
| 50 | value = _underscore_dict(value) |
| 51 | if isinstance(key, str): |
| 52 | key = underscore(key) |
| 53 | new_dictionary[key] = value |
| 54 | return new_dictionary |
| 55 | |
| 56 | |
| 57 | def json_underscore(body, charset="utf-8", **kwargs): |
no test coverage detected