Browse Source

Re-enable jshint with a minimal configuration

dev1
Lyubo Marinov 8 years ago
parent
commit
72290d937e
5 changed files with 11 additions and 44 deletions
  1. 0
    24
      .jshintignore
  2. 2
    12
      .jshintrc
  3. 7
    4
      JitsiConferenceEventManager.js
  4. 0
    2
      modules/RTC/JitsiRemoteTrack.js
  5. 2
    2
      modules/RTC/RTCUtils.js

+ 0
- 24
.jshintignore View File

@@ -9,27 +9,3 @@ lib-jitsi-meet.min.js
9 9
 # The following are checked by ESLint and take advantage of advanced language
10 10
 # features such as Facebook Flow which are not supported by JSHint.
11 11
 flow-typed/
12
-
13
-JitsiConference.js
14
-JitsiConnection.js
15
-JitsiMeetJS.js
16
-JitsiParticipant.js
17
-modules/RTC/JitsiLocalTrack.js
18
-modules/RTC/JitsiRemoteTrack.js
19
-modules/RTC/JitsiTrack.js
20
-modules/RTC/DataChannels.js
21
-modules/RTC/adapter.screenshare.js
22
-modules/RTC/RTC.js
23
-modules/RTC/RTCUtils.js
24
-modules/RTC/TraceablePeerConnection.js
25
-modules/statistics/LocalStatsCollector.js
26
-modules/statistics/RTPStatsCollector.js
27
-modules/statistics/statistics.js
28
-modules/xmpp/ChatRoom.js
29
-modules/xmpp/JingleSessionPC.js
30
-modules/xmpp/LocalSSRCReplacement.js
31
-modules/xmpp/SDP.js
32
-modules/xmpp/SDPUtil.js
33
-modules/xmpp/strophe.emuc.js
34
-modules/xmpp/strophe.jingle.js
35
-modules/xmpp/xmpp.js

+ 2
- 12
.jshintrc View File

@@ -1,20 +1,10 @@
1 1
 {
2
-    // Refer to http://jshint.com/docs/options/ for an exhaustive list of options
3
-    "asi": false, // true: Tolerate Automatic Semicolon Insertion (no semicolons)
4 2
     "browser": true, // Web Browser (window, document, etc)
5
-    "curly": false, // true: Require {} for every new block or scope
6 3
     "esversion": 6,
7
-    "evil": true, // true: Tolerate use of `eval` and `new Function()`
8 4
     "expr": true, // true: Tolerate `ExpressionStatement` as Programs
9
-    "indent": 4, // {int} Number of spaces to use for indentation
5
+    "jasmine": true,
10 6
     "latedef": false, //This option prohibits the use of a variable before it was defined
11 7
     "laxbreak": true, //Ignore line breaks around "=", "==", "&&", etc.
12 8
     "loopfunc": true, // true: Tolerate functions being defined in loops
13
-    "maxlen": 80, // {int} Max number of characters per line
14
-    "newcap": true, // true: Require capitalization of all constructor functions e.g. `new F()`
15
-    "node": true, // Node.js
16
-    "trailing": true,
17
-    "undef": true, // true: Require all non-global variables to be declared (prevents global leaks)
18
-    "white": true,
19
-    "jasmine": true
9
+    "node": true // Node.js
20 10
 }

+ 7
- 4
JitsiConferenceEventManager.js View File

@@ -500,8 +500,9 @@ JitsiConferenceEventManager.prototype.setupXMPPListeners = function() {
500 500
 
501 501
     conference.xmpp.caps.addListener(XMPPEvents.PARTCIPANT_FEATURES_CHANGED,
502 502
         from => {
503
-            const participant = conference.getParticipantId(
504
-                Strophe.getResourceFromJid(from));
503
+            const participant
504
+                = conference.getParticipantId(
505
+                    Strophe.getResourceFromJid(from));
505 506
 
506 507
             if (participant) {
507 508
                 conference.eventEmitter.emit(
@@ -510,9 +511,11 @@ JitsiConferenceEventManager.prototype.setupXMPPListeners = function() {
510 511
             }
511 512
         });
512 513
     conference.xmpp.addListener(
513
-        XMPPEvents.CALL_INCOMING, conference.onIncomingCall.bind(conference));
514
+        XMPPEvents.CALL_INCOMING,
515
+        conference.onIncomingCall.bind(conference));
514 516
     conference.xmpp.addListener(
515
-        XMPPEvents.CALL_ENDED, conference.onCallEnded.bind(conference));
517
+        XMPPEvents.CALL_ENDED,
518
+        conference.onCallEnded.bind(conference));
516 519
 
517 520
     conference.xmpp.addListener(XMPPEvents.START_MUTED_FROM_FOCUS,
518 521
         (audioMuted, videoMuted) => {

+ 0
- 2
modules/RTC/JitsiRemoteTrack.js View File

@@ -1,5 +1,3 @@
1
-/* global */
2
-
3 1
 const JitsiTrack = require('./JitsiTrack');
4 2
 
5 3
 import * as JitsiTrackEvents from '../../JitsiTrackEvents';

+ 2
- 2
modules/RTC/RTCUtils.js View File

@@ -2,9 +2,9 @@
2 2
           __filename,
3 3
           attachMediaStream,
4 4
           MediaStreamTrack,
5
-          RTCIceCandidate,
5
+          RTCIceCandidate: true,
6 6
           RTCPeerConnection,
7
-          RTCSessionDescription,
7
+          RTCSessionDescription: true,
8 8
           mozRTCIceCandidate,
9 9
           mozRTCPeerConnection,
10 10
           mozRTCSessionDescription,

Loading…
Cancel
Save