vendor/opentok.js
function versionGEThan (otherVersion) {
      if (otherVersion === version) return true;

      if (typeof(otherVersion) === 'number' && typeof(version) === 'number') {
        return otherVersion > version;
      }

      // The versions have multiple components (i.e. 0.10.30) and
      // must be compared piecewise.
      // Note: I'm ignoring the case where one version has multiple
      // components and the other doesn't.
      var v1 = otherVersion.split('.'),
          v2 = version.split('.'),
          versionLength = (v1.length > v2.length ? v2 : v1).length;

      for (var i = 0; i < versionLength; ++i) {
        if (parseInt(v1[i], 10) > parseInt(v2[i], 10)) {
          return true;
        }
      }

      // Special case, v1 has extra components but the initial components
      // were identical, we assume this means newer but it might also mean
      // that someone changed versioning systems.
      if (i < v1.length) {
        return true;
      }

      return false;
    }
function versionGEThan (otherVersion) {
      if (otherVersion === version) return true;

      if (typeof(otherVersion) === 'number' && typeof(version) === 'number') {
        return otherVersion > version;
      }

      // The versions have multiple components (i.e. 0.10.30) and
      // must be compared piecewise.
      // Note: I'm ignoring the case where one version has multiple
      // components and the other doesn't.
      var v1 = otherVersion.split('.'),
          v2 = version.split('.'),
          versionLength = (v1.length > v2.length ? v2 : v1).length;

      for (var i = 0; i < versionLength; ++i) {
        if (parseInt(v1[i], 10) > parseInt(v2[i], 10)) {
          return true;
        }
      }

      // Special case, v1 has extra components but the initial components
      // were identical, we assume this means newer but it might also mean
      // that someone changed versioning systems.
      if (i < v1.length) {
        return true;
      }

      return false;
    }
function versionGEThan ( otherVersion ) { if ( otherVersion === version ) return true ; if ( typeof ( otherVersion ) === 'number' && typeof ( version ) === 'number' ) { return otherVersion > version ; } // The versions have multiple components (i.e. 0.10.30) and // must be compared piecewise. // Note: I'm ignoring the case where one version has multiple // components and the other doesn't. var v1 = otherVersion . split ( '.' ) , v2 = version . split ( '.' ) , versionLength = ( v1 . length > v2 . length ? v2 : v1 ) . length ; for ( var i = 0 ; i < versionLength ; ++ i ) { if ( parseInt ( v1 [ i ] , 10 ) > parseInt ( v2 [ i ] , 10 ) ) { return true ; } } // Special case, v1 has extra components but the initial components // were identical, we assume this means newer but it might also mean // that someone changed versioning systems. if ( i < v1 . length ) { return true ; } return false ; }
Returns true if otherVersion is greater than the current environment version.
Returns true if otherVersion is greater than the current environment version .