浏览代码

fix(JitsiConference|stats): use 'sendToAll'

Use 'sendToAll' for 'session.restart' and 'session.terminate' events.
master
paweldomas 9 年前
父节点
当前提交
5a8ed28287
共有 1 个文件被更改,包括 3 次插入7 次删除
  1. 3
    7
      JitsiConference.js

+ 3
- 7
JitsiConference.js 查看文件

@@ -793,8 +793,7 @@ function (jingleSession, jingleOffer, now) {
793 793
     this.room.connectionTimes["session.initiate"] = now;
794 794
     // Log "session.restart"
795 795
     if (this.wasStopped) {
796
-        Statistics.analytics.sendEvent("session.restart", now);
797
-        this.sendApplicationLog(JSON.stringify({ "id" : "session_restart"}));
796
+        Statistics.sendEventToAll("session.restart");
798 797
     }
799 798
     // add info whether call is cross-region
800 799
     var crossRegion = null;
@@ -876,11 +875,8 @@ JitsiConference.prototype.onCallEnded
876 875
 = function (JingleSession, reasonCondition, reasonText) {
877 876
     logger.info("Call ended: " + reasonCondition + " - " + reasonText);
878 877
     this.wasStopped = true;
879
-    // Send analytics event
880
-    Statistics.analytics.sendEvent(
881
-        "session.terminate", window.performance.now());
882
-    // Sends "session.terminate" through the stats as well
883
-    this.sendApplicationLog(JSON.stringify({ "id" : "session_terminate" }));
878
+    // Send session.terminate event
879
+    Statistics.sendEventToAll("session.terminate");
884 880
     // Stop the stats
885 881
     if (this.statistics) {
886 882
         this.statistics.stopRemoteStats();

正在加载...
取消
保存