refactor: add field to APIError struct
This commit is contained in:
@@ -23,6 +23,8 @@ type APIError struct {
|
||||
Message string `json:"message"`
|
||||
// Additional error details
|
||||
Details string `json:"details,omitempty"`
|
||||
// Field name if applicable
|
||||
Field string `json:"field,omitempty" example:"name"`
|
||||
}
|
||||
|
||||
const content_type = "Content-Type"
|
||||
|
||||
Reference in New Issue
Block a user