10 lines
279 B
Python
10 lines
279 B
Python
from fastapi import HTTPException, status
|
|
|
|
|
|
class BaseError(HTTPException):
|
|
status_code: int = status.HTTP_500_INTERNAL_SERVER_ERROR
|
|
|
|
def __init__(self, detail: str):
|
|
self.detail = detail
|
|
super().__init__(status_code=self.status_code, detail=self.detail)
|