Merge pull request #35 from TouchInstinct/fix/not-found-resolver

Fix NotFoundExceptionResolver
This commit is contained in:
Mikhail Yasnov 2021-07-12 18:22:19 +03:00 committed by GitHub
commit 6dd6be5a91
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23
1 changed files with 2 additions and 2 deletions

View File

@ -11,8 +11,8 @@ import ru.touchin.exception.handler.dto.ExceptionResolverResult
class NotFoundExceptionResolver : ExceptionResolver {
override fun invoke(exception: Exception): ExceptionResolverResult? {
if (exception !is CommonNotFoundException) {
ExceptionResolverResult.createNotFoundError(exception)
if (exception is CommonNotFoundException) {
return ExceptionResolverResult.createNotFoundError(exception)
}
return null