throw error if missing MOVIE_WEB_TMDB_API_KEY

This commit is contained in:
Jonathan Barrow
2023-09-26 13:25:54 -04:00
parent 6f29b636ea
commit 7804b3bf91

View File

@@ -38,6 +38,10 @@ type CommandLineArguments = {
const TMDB_API_KEY = process.env.MOVIE_WEB_TMDB_API_KEY;
if (!TMDB_API_KEY?.trim()) {
throw new Error('Missing MOVIE_WEB_TMDB_API_KEY environment variable');
}
const sources = getAllSources();
function getAllSources() {