@ -22,7 +22,6 @@ export class McpToolExceptionFilter implements RpcExceptionFilter {
public catch(exception: unknown): Observable<never> {
this.logger.error(exception);
// The payload is written for the caller already
if (exception instanceof RpcException) {
return throwError(() => {
return exception.getError();
@ -70,8 +70,8 @@ describe('Scopes', () => {
it('Without the scope to read the values', () => {
expect(
getScopesOfAccess({
type: 'PRIVATE',
scopes: [scopes.portfolioRead]
scopes: [scopes.portfolioRead],
type: 'PRIVATE'
})
).not.toContain(scopes.portfolioReadValues);
});
@ -94,8 +94,7 @@ export function getScopesOfAccess({
}): string[] {
const scopesToEvaluate = scopesOfAccess ?? [];
// An unknown scope is dropped, so that a scope which has been removed from
// the vocabulary cannot stay effective
// An unknown scope is dropped
return SCOPES_OF_TYPE[type].filter((scope) => {
return scopesToEvaluate.includes(scope);