diff --git a/api/generate-api-docs.js b/api/generate-api-docs.js index 6c6f2de56a..0268d6b6fa 100644 --- a/api/generate-api-docs.js +++ b/api/generate-api-docs.js @@ -21,7 +21,7 @@ function runCommand(command) { // API name must be passed in as an arg. const api = process.argv[2]; if (api === undefined) { - const validAPIs = string.join(apiStrategies.join, ", "); + const validAPIs = Object.keys(apiStrategies).join(", "); console.log(`Please specify an API name. Valid names: ${validAPIs}`); process.exit(); } @@ -29,7 +29,7 @@ if (api === undefined) { // The API name must be recognized. const strategy = apiStrategies[api]; if (strategy === undefined) { - const validAPIs = string.join(apiStrategies.join, ", "); + const validAPIs = Object.keys(apiStrategies).join(", "); console.error(`Invalid API name ${api}. Valid names: ${validAPIs}`); process.exit(); }