Skip to content

Commit 2b123dc

Browse files
committed
Use NullChannel return type explicitly
1 parent 24e75f7 commit 2b123dc

File tree

1 file changed

+2
-4
lines changed

1 file changed

+2
-4
lines changed

src/connector/null-connector.ts

Lines changed: 2 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -1,8 +1,6 @@
11
import { Connector } from './connector';
22
import { NullChannel, NullPrivateChannel, NullPresenceChannel, NullEncryptedPrivateChannel } from './../channel';
33

4-
type AnyNullChannel = NullChannel | NullPrivateChannel | NullEncryptedPrivateChannel | NullPresenceChannel;
5-
64
/**
75
* This class creates a null connector.
86
*/
@@ -22,14 +20,14 @@ export class NullConnector extends Connector<NullChannel, NullPrivateChannel, Nu
2220
/**
2321
* Listen for an event on a channel instance.
2422
*/
25-
listen(name: string, event: string, callback: Function): AnyNullChannel {
23+
listen(name: string, event: string, callback: Function): NullChannel {
2624
return new NullChannel();
2725
}
2826

2927
/**
3028
* Get a channel instance by name.
3129
*/
32-
channel(name: string): AnyNullChannel {
30+
channel(name: string): NullChannel {
3331
return new NullChannel();
3432
}
3533

0 commit comments

Comments
 (0)