fix
This commit is contained in:
parent
8437348fb5
commit
5d02c9719d
@ -25,12 +25,12 @@ type Errors []error
|
||||
func IsRecordNotFoundError(err error) bool {
|
||||
if errs, ok := err.(Errors); ok {
|
||||
for _, err := range errs {
|
||||
if err == ErrRecordNotFound {
|
||||
if err.Error() == ErrRecordNotFound.Error() {
|
||||
return true
|
||||
}
|
||||
}
|
||||
}
|
||||
return err == ErrRecordNotFound
|
||||
return err.Error() == ErrRecordNotFound.Error()
|
||||
}
|
||||
|
||||
// GetErrors gets all errors that have occurred and returns a slice of errors (Error type)
|
||||
|
Loading…
x
Reference in New Issue
Block a user