source: node_modules/detect-libc/lib/process.js@ 62b2964

finki-main main
Last change on this file since 62b2964 was 81bc7da, checked in by Klimentina Efremova <klimentina08642@…>, 3 months ago

Initial commit

  • Property mode set to 100644
File size: 569 bytes
Line 
1// Copyright 2017 Lovell Fuller and others.
2// SPDX-License-Identifier: Apache-2.0
3
4'use strict';
5
6const isLinux = () => process.platform === 'linux';
7
8let report = null;
9const getReport = () => {
10 if (!report) {
11 /* istanbul ignore next */
12 if (isLinux() && process.report) {
13 const orig = process.report.excludeNetwork;
14 process.report.excludeNetwork = true;
15 report = process.report.getReport();
16 process.report.excludeNetwork = orig;
17 } else {
18 report = {};
19 }
20 }
21 return report;
22};
23
24module.exports = { isLinux, getReport };
Note: See TracBrowser for help on using the repository browser.