Another Fetching featured packages failed error message

Hi folks,
I’m running ArcoLinux, not sure exactly what cause this, but it happened after installing jdk8 for Freemind, since removed. I don’t program but I cleaned up the output by editing a few lines. The error is now down to this:
/usr/lib/node_modules/atom-package-manager/lib/request.js:22
if (requestOptions.proxy == null) {
^

ReferenceError: requestOptions is not defined
at Object. (/usr/lib/node_modules/atom-package-manager/lib/request.js:22:7)
at Object.onceWrapper (node:events:483:26)
at Object.emit (node:events:376:20)
at /usr/lib/node_modules/npm/lib/npm.js:151:12

Link to my pastebin for request.js and npm.js

This is the code around the lines in question (hope it includes enough):

  // call with parsed CLI options and a callback when done loading

// XXX promisify this and stop taking a callback
load (cb) {
if (!cb || typeof cb !== ‘function’)
throw new TypeError(‘must call as: npm.load(callback)’)

this.once('load', cb)
if (this.loaded || this.loadErr) {
  this.emit('load', this.loadErr)
  return
}
if (this.loading)
  return

this.loading = true

process.emit('time', 'npm:load')
this.log.pause()
return this[_load]().catch(er => er).then((er) => {
  this.loading = false
  this.loadErr = er
  if (!er && this.config.get('force'))
    this.log.warn('using --force', 'Recommended protections disabled.')

  if (!er && !this[_flatOptions])
    this[_flatOptions] = require('./utils/flat-options.js')(this)

  process.emit('timeEnd', 'npm:load')
  this.emit('load', er)
})

}

and

(function() {

var config, configureRequest, loadNpm, npm, request;

npm = require(‘npm’);

request = require(‘request’);

config = require(’./apm’);

loadNpm = function(callback) {
var npmOptions;
npmOptions = {
userconfig: config.getUserConfigPath(),
globalconfig: config.getGlobalConfigPath()
};
return npm.load(callback);
};

configureRequest = function(callback) {
return loadNpm(function() {
var base, ref, userAgent;
if (requestOptions.proxy == null) {
requestOptions.proxy = npm.config.get(‘https-proxy’) || npm.config.get(‘proxy’) || process.env.HTTPS_PROXY || process.env.HTTP_PROXY;
}
if (requestOptions.strictSSL == null) {
requestOptions.strictSSL = npm.config.get(‘strict-ssl’);
}
userAgent = (ref = npm.config.get(‘user-agent’)) != null ? ref : “AtomApm/” + (require(’…/package.json’).version);
if (requestOptions.headers == null) {
requestOptions.headers = {};
}
if ((base = requestOptions.headers)[‘User-Agent’] == null) {
base[‘User-Agent’] = userAgent;
}
return callback();
});
};

I’m sure it’s pretty obvious, but it’s over my head atm. If there’s more info need, please let me know. Thanks for reading this far. :slight_smile: