修正
This commit is contained in:
Binary file not shown.
Binary file not shown.
BIN
backend/app/core/__pycache__/exceptions.cpython-312.pyc
Normal file
BIN
backend/app/core/__pycache__/exceptions.cpython-312.pyc
Normal file
Binary file not shown.
11
backend/app/core/exceptions.py
Normal file
11
backend/app/core/exceptions.py
Normal file
@@ -0,0 +1,11 @@
|
||||
from fastapi import HTTPException
|
||||
|
||||
class BusinessException(HTTPException):
|
||||
def __init__(self, error_code: str, message: str):
|
||||
super().__init__(
|
||||
status_code=400,
|
||||
detail={
|
||||
"error_code": error_code,
|
||||
"message": message
|
||||
}
|
||||
)
|
||||
Reference in New Issue
Block a user