-
Notifications
You must be signed in to change notification settings - Fork 126
Open
Labels
bugSomething isn't workingSomething isn't working
Description
Server crashes when a non existent api is called on server. Error occurs in error parsing step. Specifically on below lines.
func ParseError(err error) ProblemDetailErr {
stackTrace := errorUtils.ErrorsWithStack(err)
customErr := customErrors.GetCustomError(err)
var validatorErr validator.ValidationErrors
if err != nil {
switch {
case customErrors.IsDomainError(err, customErr.Status()):
return NewDomainProblemDetail(customErr.Status(), customErr.Error(), stackTrace)
2nd line of function returns nil when we try to create custom error. and subsequent calls on nil causes panic which causes crash.
Reactions are currently unavailable
Metadata
Metadata
Assignees
Labels
bugSomething isn't workingSomething isn't working