uWebSockets.js/dist/uws.js
2018-11-03 12:35:42 +01:00

11 lines
361 B
JavaScript

module.exports = (() => {
try {
const uWS = require(`./uws_${process.platform}_${process.versions.modules}.node`);
/* We are not compatible with Node.js domain */
process.nextTick = (f, ...args) => uWS.nextTick(f.apply(...args));
return uWS;
} catch (e) {
throw new Error('This version of µWS is not compatible with your Node.js build.');
}
})();