mirror of
https://github.com/serengil/deepface.git
synced 2025-06-08 04:25:21 +00:00
15 lines
368 B
Python
15 lines
368 B
Python
from flask import (Response)
|
|
from json import dumps
|
|
|
|
|
|
def send_json_response(body, status):
|
|
"""
|
|
format json response
|
|
:param body: dic object going to send
|
|
:param status: response status
|
|
:return: formatted response
|
|
"""
|
|
return Response(response=dumps(body),
|
|
status=status,
|
|
mimetype="application/json")
|