Skip to content

Commit

Permalink
fix: real, actual javascript in api generators (#4788)
Browse files Browse the repository at this point in the history
  • Loading branch information
pepopowitz authored Dec 18, 2024
1 parent 5d9af3d commit f2efb13
Showing 1 changed file with 2 additions and 2 deletions.
4 changes: 2 additions & 2 deletions api/generate-api-docs.js
Original file line number Diff line number Diff line change
Expand Up @@ -21,15 +21,15 @@ 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();
}

// 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();
}
Expand Down

0 comments on commit f2efb13

Please sign in to comment.