src/wtf/trace/providers/webglprovider.js
function checkInstrumented() {
      if (proto['__gl_wrapped__']) {
        return false;
      }
      Object.defineProperty(proto, '__gl_wrapped__', {
        'configurable': true,
        'enumerable': false,
        'value': true
      });
      contextRestoreFns.push(function() {
        delete proto['__gl_wrapped__'];
      });
      return true;
    }
function checkInstrumented() {
      if (proto['__gl_wrapped__']) {
        return false;
      }
      Object.defineProperty(proto, '__gl_wrapped__', {
        'configurable': true,
        'enumerable': false,
        'value': true
      });
      contextRestoreFns.push(function() {
        delete proto['__gl_wrapped__'];
      });
      return true;
    }
function checkInstrumented ( ) { if ( proto [ '__gl_wrapped__' ] ) { return false ; } Object . defineProperty ( proto , '__gl_wrapped__' , { 'configurable' : true , 'enumerable' : false , 'value' : true } ) ; contextRestoreFns . push ( function ( ) { delete proto [ '__gl_wrapped__' ] ; } ) ; return true ; }
We do this check only for known extensions, as Firefox will return a generic 'Object' for others and that will break everything.
We do this check only for known extensions as Firefox will return a generic Object for others and that will break everything .