A JSON response for a successful request. Args: data: Dictionary with JSON properties to include. Returns: A `flask.Response` object with JSON body containing the serialized data.
(data={})
| 4 | # The default dictionary is okay because we're not modifying it. |
| 5 | # pylint: disable=dangerous-default-value |
| 6 | def success(data={}): |
| 7 | """A JSON response for a successful request. |
| 8 | |
| 9 | Args: |
| 10 | data: Dictionary with JSON properties to include. |
| 11 | |
| 12 | Returns: |
| 13 | A `flask.Response` object with JSON body containing the serialized data. |
| 14 | """ |
| 15 | return flask.jsonify(data) |
| 16 | |
| 17 | |
| 18 | def error(original_error): |
nothing calls this directly
no outgoing calls
no test coverage detected