diff --git a/src/@types/is-root.d.ts b/src/@types/is-root.d.ts new file mode 100644 index 0000000000..45d5671bfc --- /dev/null +++ b/src/@types/is-root.d.ts @@ -0,0 +1,5 @@ +declare module 'is-root'; + +declare namespace isRoot { + export function isRoot(): boolean; +} diff --git a/src/index.ts b/src/index.ts index 13510c9b49..310fae9968 100644 --- a/src/index.ts +++ b/src/index.ts @@ -11,7 +11,7 @@ import * as cluster from 'cluster'; import * as debug from 'debug'; import chalk from 'chalk'; import * as portscanner from 'portscanner'; -import isRoot = require('is-root'); +import * as isRoot from 'is-root'; import Xev from 'xev'; import * as program from 'commander'; import * as sysUtils from 'systeminformation';