Secure your code as it's written. Use Snyk Code to scan source code in minutes - no build needed - and fix issues immediately.
public async onSubscriptionConnect(connectionParams: any, webSocket: any, context: any): Promise {
const keycloakSubscriptionHandler = new KeycloakSubscriptionHandler({ keycloak: this.keycloak })
const token = await keycloakSubscriptionHandler.onSubscriptionConnect(connectionParams, webSocket, context)
const subscriptionContext = new KeycloakSubscriptionContext(token as any) // TODO fix type
return {
kauth: subscriptionContext,
auth: subscriptionContext // keep backwards compatibility with voyager-server
}
}
}
public async onSubscriptionConnect(connectionParams: any, webSocket: any, context: any): Promise {
const keycloakSubscriptionHandler = new KeycloakSubscriptionHandler({ keycloak: this.keycloak })
const token = await keycloakSubscriptionHandler.onSubscriptionConnect(connectionParams, webSocket, context)
const subscriptionContext = new KeycloakSubscriptionContext(token as any) // TODO fix type
return {
kauth: subscriptionContext,
auth: subscriptionContext // keep backwards compatibility with voyager-server
}
}
}