U
    ð¤ùd   ã                   @   sP   zd dl mZ W n  ek
r0   d dlmZ Y nX d dlmZmZ ddd„ZdS )é    )Údumps)Úmake_responseÚcurrent_appNc                 C   sN   t j di ¡}t jr | dd¡ t| f|Žd }t||ƒ}|j |pFi ¡ |S )z/Makes a Flask response with a JSON encoded bodyZ
RESTX_JSONÚindenté   Ú
)	r   ÚconfigÚgetÚdebugÚ
setdefaultr   r   ÚheadersÚextend)ÚdataÚcoder   ÚsettingsZdumpedÚresp© r   ú?/tmp/pip-unpacked-wheel-dt_sn2ih/flask_restx/representations.pyÚoutput_json	   s    
r   )N)Zujsonr   ÚImportErrorÚjsonZflaskr   r   r   r   r   r   r   Ú<module>   s
   