Fix formatting in endpoints/api/error.py
This commit is contained in:
parent
1cdbd89120
commit
d67c4ba46c
1 changed files with 13 additions and 7 deletions
|
@ -1,6 +1,5 @@
|
|||
""" Error details API """
|
||||
from flask import url_for
|
||||
from enum import Enum
|
||||
|
||||
from endpoints.api import (resource, nickname, ApiResource, path_param,
|
||||
define_json_response)
|
||||
|
@ -34,12 +33,18 @@ class Error(ApiResource):
|
|||
},
|
||||
'title': {
|
||||
'type': 'string',
|
||||
'description': 'The title of the error. Can be used to uniquely identify the kind of error.',
|
||||
'description': (
|
||||
'The title of the error. Can be used to uniquely identify the kind'
|
||||
' of error.'
|
||||
),
|
||||
'enum': list(ApiErrorType.__members__)
|
||||
},
|
||||
'description': {
|
||||
'type': 'string',
|
||||
'description': 'A more detailed description of the error that may include help for fixing the issue.'
|
||||
'description': (
|
||||
'A more detailed description of the error that may include help for'
|
||||
' fixing the issue.'
|
||||
)
|
||||
}
|
||||
},
|
||||
},
|
||||
|
@ -51,5 +56,6 @@ class Error(ApiResource):
|
|||
""" Get a detailed description of the error """
|
||||
if error_type in ERROR_DESCRIPTION.keys():
|
||||
return error_view(error_type)
|
||||
|
||||
raise NotFound()
|
||||
|
||||
|
|
Reference in a new issue