Created
September 18, 2022 15:04
-
-
Save bnb/087d9449211ef536d8fe63147040dee1 to your computer and use it in GitHub Desktop.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
async function parseOptions (options) { | |
const parsedOptions = { | |
urls: { | |
index: 'https://nodejs.org/dist/index.json', | |
schedule: 'https://raw.githubusercontent.com/nodejs/Release/master/schedule.json' | |
} | |
} | |
if(options?.urls?.index) { | |
parsedOptions.urls.index = options.urls.index | |
} | |
if(options?.urls?.schedule) { | |
parsedOptions.urls.schedule = options.urls.schedule | |
} | |
} |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment