@@ -1,16 +1,15 @@
|
||||
|
||||
import program from './commander';
|
||||
|
||||
function logStartupOptions(options) {
|
||||
for (const key in options) {
|
||||
let value = options[key];
|
||||
if (key == "masterKey") {
|
||||
value = "***REDACTED***";
|
||||
if (key == 'masterKey') {
|
||||
value = '***REDACTED***';
|
||||
}
|
||||
if (typeof value === 'object') {
|
||||
try {
|
||||
value = JSON.stringify(value)
|
||||
} catch(e) {
|
||||
value = JSON.stringify(value);
|
||||
} catch (e) {
|
||||
if (value && value.constructor && value.constructor.name) {
|
||||
value = value.constructor.name;
|
||||
}
|
||||
@@ -22,12 +21,7 @@ function logStartupOptions(options) {
|
||||
}
|
||||
}
|
||||
|
||||
export default function({
|
||||
definitions,
|
||||
help,
|
||||
usage,
|
||||
start
|
||||
}) {
|
||||
export default function({ definitions, help, usage, start }) {
|
||||
program.loadDefinitions(definitions);
|
||||
if (usage) {
|
||||
program.usage(usage);
|
||||
|
||||
Reference in New Issue
Block a user