HEX
Server: Apache
System: Linux webd004.cluster130.gra.hosting.ovh.net 5.15.206-ovh-vps-grsec-zfs-classid #1 SMP Fri May 15 02:41:25 UTC 2026 x86_64
User: frenchy (106757)
PHP: 7.4.33
Disabled: _dyuweyrj4,_dyuweyrj4r,dl
Upload Files
File: /home/frenchy/www/french-american.org/releases/20210421135930Z/node_modules/rechoir/lib/register.js
const path = require('path');
const resolve = require('resolve');

module.exports = function (cwd, moduleName, register) {
  try {
    var modulePath = resolve.sync(moduleName, {basedir: cwd});
    var result = require(modulePath);
    if (typeof register === 'function') {
      register(result);
    }
  } catch (e) {
    result = e;
  }
  return result;
};