mirror of
https://github.com/Inside4ndroid/TMDB-Embed-API.git
synced 2026-10-23 18:15:09 +00:00
Full overhaul of the repo please see changelog
This commit is contained in:
1 parent
2119398460
commit
e0ad35d2b1
115 files changed
+26066
-6426
No files matched your search
@@ -0,0 +1,12 @@
|
||||
const { config } = require('./config');
|
||||
|
||||
function getTmdbApiKey() {
|
||||
if (config.tmdbApiKeys && config.tmdbApiKeys.length) {
|
||||
const idx = Math.floor(Math.random() * config.tmdbApiKeys.length);
|
||||
return config.tmdbApiKeys[idx];
|
||||
}
|
||||
// Fallback legacy single value (config or env)
|
||||
return config.tmdbApiKey || process.env.TMDB_API_KEY || null;
|
||||
}
|
||||
|
||||
module.exports = { getTmdbApiKey };
|
||||
Reference in new issue
Block a user