|
@@ -86,7 +86,7 @@ class RtcEngine {
|
86
|
86
|
* @param eventType
|
87
|
87
|
*/
|
88
|
88
|
public static off(eventType: string) {
|
89
|
|
- AgoraEventEmitter.removeAllListeners(eventType);
|
|
89
|
+ AgoraEventEmitter.removeListener(eventType, () => {});
|
90
|
90
|
this.eventTypes.delete(eventType);
|
91
|
91
|
}
|
92
|
92
|
|
|
@@ -99,7 +99,7 @@ class RtcEngine {
|
99
|
99
|
*/
|
100
|
100
|
public static removeAllListeners() {
|
101
|
101
|
for (let eventType of this.eventTypes) {
|
102
|
|
- AgoraEventEmitter.removeAllListeners(eventType);
|
|
102
|
+ AgoraEventEmitter.removeListener(eventType, () => {});
|
103
|
103
|
}
|
104
|
104
|
this.eventTypes.clear();
|
105
|
105
|
}
|