Changed tmdb constructor to have apiKey as first parameter. If cache is not defined we use redis.
This commit is contained in:
@@ -1,9 +1,6 @@
|
||||
const configuration = require('src/config/configuration').getInstance();
|
||||
const Cache = require('src/tmdb/cache');
|
||||
const TMDB = require('src/tmdb/tmdb');
|
||||
|
||||
const cache = new Cache();
|
||||
const tmdb = new TMDB(cache, configuration.get('tmdb', 'apiKey'));
|
||||
const tmdb = new TMDB(configuration.get('tmdb', 'apiKey'));
|
||||
|
||||
const showCreditsController = (req, res) => {
|
||||
const showId = req.params.id;
|
||||
@@ -23,4 +20,4 @@ const showCreditsController = (req, res) => {
|
||||
})
|
||||
}
|
||||
|
||||
module.exports = showCreditsController;
|
||||
module.exports = showCreditsController;
|
||||
|
||||
Reference in New Issue
Block a user