mirror of
https://github.com/etesync/server
synced 2024-12-26 17:28:08 +00:00
d8e5c37db1
Merge #65
10 lines
308 B
Python
10 lines
308 B
Python
from rest_framework import serializers, status
|
|
|
|
|
|
class EtebaseValidationError(serializers.ValidationError):
|
|
def __init__(self, code, detail, status_code=status.HTTP_400_BAD_REQUEST):
|
|
super().__init__(
|
|
{"code": code, "detail": detail,}
|
|
)
|
|
self.status_code = status_code
|