Skip to content

Commit

Permalink
fix: revert to forbidden exception
Browse files Browse the repository at this point in the history
  • Loading branch information
SuperBatata committed Jul 8, 2024
1 parent 2117819 commit be7bb62
Showing 1 changed file with 2 additions and 1 deletion.
Original file line number Diff line number Diff line change
Expand Up @@ -21,6 +21,7 @@ import id.walt.webwallet.service.WalletServiceManager
import id.walt.webwallet.service.WalletServiceManager.oidcConfig
import id.walt.webwallet.service.account.AccountsService
import id.walt.webwallet.service.account.KeycloakAccountStrategy
import id.walt.webwallet.web.ForbiddenException
import id.walt.webwallet.web.InsufficientPermissionsException
import id.walt.webwallet.web.UnauthorizedException
import id.walt.webwallet.web.WebBaseRoutes.webWalletRoute
Expand Down Expand Up @@ -578,7 +579,7 @@ fun PipelineContext<Unit, ApplicationCall>.ensurePermissionsForWallet(
(AccountWalletMappings.wallet eq walletId)
}
.firstOrNull()
?: throw NotFoundException("This account does not have access to the specified wallet."))[
?: throw ForbiddenException("This account does not have access to the specified wallet."))[
AccountWalletMappings.permissions]
}

Expand Down

0 comments on commit be7bb62

Please sign in to comment.