Secure your code as it's written. Use Snyk Code to scan source code in minutes - no build needed - and fix issues immediately.
function doOperation(
socket: ReactiveSocket,
operation: string,
payload: string,
): Flowable> {
switch (operation) {
case 'none':
return Flowable.never();
case 'stream':
default:
console.log(`Requesting stream with payload: ${payload}`);
return socket.requestStream({
data: payload,
metadata: '',
});
}
}
_sender: (?T) => Flowable = () => Flowable.never();
_receiver: (Flowable) => void = leases => {};