Passed
Push — master ( b8824f...085104 )
by Mingyu
01:01
created

app.hooks.error.broad_exception_handler()   A

Complexity

Conditions 1

Size

Total Lines 2
Code Lines 2

Duplication

Lines 0
Ratio 0 %

Importance

Changes 0
Metric Value
cc 1
eloc 2
nop 1
dl 0
loc 2
rs 10
c 0
b 0
f 0
1
from werkzeug.exceptions import HTTPException
2
3
4
def http_exception_handler(e: HTTPException):
5
    return '', e.code
6
7
8
def broad_exception_handler(e: Exception):
9
    return '', 500
10