代码拉取完成,页面将自动刷新
"use strict";
const os = require("os");
const platform = os.platform();
if (["aix", "android", "darwin", "freebsd", "linux", "openbsd", "sunos", "win32"].includes(platform)) {
let file;
if (platform === "aix") {
// AIX `netstat` output is compatible with Solaris
file = `${os.type() === "OS400" ? "ibmi" : "sunos"}.js`;
} else {
file = `${platform}.js`;
}
const m = require(`./${file}`);
module.exports.v4 = () => m.v4();
module.exports.v6 = () => m.v6();
module.exports.v4.sync = () => m.v4.sync();
module.exports.v6.sync = () => m.v6.sync();
} else {
const unsupported = () => {throw new Error(`Unsupported Platform: ${platform}`)};
module.exports.v4 = unsupported;
module.exports.v6 = unsupported;
module.exports.v4.sync = unsupported;
module.exports.v6.sync = unsupported;
}
此处可能存在不合适展示的内容,页面不予展示。您可通过相关编辑功能自查并修改。
如您确认内容无涉及 不当用语 / 纯广告导流 / 暴力 / 低俗色情 / 侵权 / 盗版 / 虚假 / 无价值内容或违法国家有关法律法规的内容,可点击提交进行申诉,我们将尽快为您处理。