dist/main.js
function record(f) {
              // TODO document why @refreshing exists
              // guards against recursively evaluating this recorded
              // function (@body or an async body) when calling `.get()`
              if (!_this10.refreshing) {
                var res = void 0;
                _this10.disconnect();
                if (recorded) {
                  throw new Error("this refresh has already recorded its dependencies");
                }
                _this10.refreshing = true;
                recorded = true;
                try {
                  res = recorder.record(_this10, function () {
                    return f.call(env);
                  });
                } finally {
                  _this10.refreshing = false;
                }
                if (isSynchronous) {
                  realDone(syncResult);
                }
                return res;
              }
            }
function record(f) {
              // TODO document why @refreshing exists
              // guards against recursively evaluating this recorded
              // function (@body or an async body) when calling `.get()`
              if (!_this10.refreshing) {
                var res = void 0;
                _this10.disconnect();
                if (recorded) {
                  throw new Error("this refresh has already recorded its dependencies");
                }
                _this10.refreshing = true;
                recorded = true;
                try {
                  res = recorder.record(_this10, function () {
                    return f.call(env);
                  });
                } finally {
                  _this10.refreshing = false;
                }
                if (isSynchronous) {
                  realDone(syncResult);
                }
                return res;
              }
            }
function record ( f ) { // TODO document why @refreshing exists // guards against recursively evaluating this recorded // function (@body or an async body) when calling `.get()` if ( ! _this10 . refreshing ) { var res = void 0 ; _this10 . disconnect ( ) ; if ( recorded ) { throw new Error ( "this refresh has already recorded its dependencies" ) ; } _this10 . refreshing = true ; recorded = true ; try { res = recorder . record ( _this10 , function ( ) { return f . call ( env ) ; } ) ; } finally { _this10 . refreshing = false ; } if ( isSynchronous ) { realDone ( syncResult ) ; } return res ; } }
next two are for tolerating env.done calls from within env.record
next two are for tolerating env . done calls from within env . record