Skip to content

Commit

Permalink
Updated deps and fixed bugs in #54 and #55
Browse files Browse the repository at this point in the history
  • Loading branch information
leocabeza committed Nov 17, 2019
1 parent b747a81 commit 4997224
Show file tree
Hide file tree
Showing 8 changed files with 138 additions and 125 deletions.
197 changes: 101 additions & 96 deletions docs/v3-api.md

Large diffs are not rendered by default.

36 changes: 18 additions & 18 deletions package-lock.json

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

6 changes: 3 additions & 3 deletions package.json
Original file line number Diff line number Diff line change
Expand Up @@ -6,17 +6,17 @@
"browser": "dist/the-movie-db.umd.js",
"dependencies": {
"cross-fetch": "^3.0.4",
"query-string": "^6.8.3"
"query-string": "^6.9.0"
},
"devDependencies": {
"@babel/plugin-transform-modules-commonjs": "^7.7.0",
"cross-env": "^6.0.3",
"husky": "^3.0.9",
"jest": "^24.9.0",
"jsdoc-to-markdown": "^5.0.2",
"lint-staged": "^9.4.2",
"lint-staged": "^9.4.3",
"prettier": "1.18.2",
"rollup": "^1.26.4",
"rollup": "^1.27.0",
"rollup-plugin-buble": "^0.19.8",
"rollup-plugin-commonjs": "^10.1.0",
"rollup-plugin-filesize": "^6.2.1",
Expand Down
6 changes: 4 additions & 2 deletions src/entities/v3/movie.js
Original file line number Diff line number Diff line change
Expand Up @@ -2,7 +2,7 @@ import { makeHttpRequest } from 'utils/utils';
import urls from 'urls/urls';

/**
* @module movies
* @module movie
*/

/**
Expand Down Expand Up @@ -126,18 +126,20 @@ export const deleteRating = async (movieId, options = {}) => {
* @param {Object} options
* @param {string} options.language
* @param {string} options.append_to_response
* @param {string} options.include_image_language
* @returns {Promise}
* @see https://developers.themoviedb.org/3/movies/get-movie-details
*/
export const details = async (movieId, options = {}) => {
const { language, append_to_response } = options;
const { language, append_to_response, include_image_language } = options;
if (!movieId) {
return Promise.reject('A movieId has to be provided');
}

return await makeHttpRequest(urls.v3.MOVIE_DETAILS.replace(':id', movieId), {
language,
append_to_response,
include_image_language,
});
};

Expand Down
4 changes: 3 additions & 1 deletion src/entities/v3/people.js
Original file line number Diff line number Diff line change
Expand Up @@ -62,11 +62,12 @@ export const combinedCredits = async (personId, options = {}) => {
* @param {Object} options
* @param {string} options.language
* @param {string} options.append_to_response
* @param {string} options.include_image_language
* @returns {Promise}
* @see https://developers.themoviedb.org/3/people/get-person-details
*/
export const details = async (personId, options = {}) => {
const { language, append_to_response } = options;
const { language, append_to_response, include_image_language } = options;

if (!personId && personId !== 0) {
return Promise.reject('A personId has to be provided');
Expand All @@ -77,6 +78,7 @@ export const details = async (personId, options = {}) => {
{
language,
append_to_response,
include_image_language,
}
);
};
Expand Down
5 changes: 3 additions & 2 deletions src/entities/v3/tv-episode.js
Original file line number Diff line number Diff line change
Expand Up @@ -158,6 +158,7 @@ export const deleteRating = async (
* @param {Object} options
* @param {string} options.language
* @param {string} options.append_to_response
* @param {string} options.include_image_language
* @returns {Promise}
* @see https://developers.themoviedb.org/3/tv-episodes/get-tv-episode-details
*/
Expand All @@ -167,7 +168,7 @@ export const details = async (
episodeNumber,
options = {}
) => {
const { language, append_to_response } = options;
const { language, append_to_response, include_image_language } = options;

if (!tvId && tvId !== 0) {
return Promise.reject('A tvId has to be provided');
Expand All @@ -185,7 +186,7 @@ export const details = async (
urls.v3.TV_EPISODE_DETAILS.replace(':tvId', tvId)
.replace(':seasonNumber', seasonNumber)
.replace(':episodeNumber', episodeNumber),
{ language, append_to_response }
{ language, append_to_response, include_image_language }
);
};

Expand Down
5 changes: 3 additions & 2 deletions src/entities/v3/tv-season.js
Original file line number Diff line number Diff line change
Expand Up @@ -102,11 +102,12 @@ export const credits = async (tvId, seasonNumber, options = {}) => {
* @param {Object} options
* @param {string} options.language
* @param {string} options.append_to_response
* @param {string} options.include_image_language
* @returns {Promise}
* @see https://developers.themoviedb.org/3/tv-seasons/get-tv-season-details
*/
export const details = async (tvId, seasonNumber, options = {}) => {
const { language, append_to_response } = options;
const { language, append_to_response, include_image_language } = options;

if (!tvId && tvId !== 0) {
return Promise.reject('A tvId has to be provided');
Expand All @@ -121,7 +122,7 @@ export const details = async (tvId, seasonNumber, options = {}) => {
':seasonNumber',
seasonNumber
),
{ language, append_to_response }
{ language, append_to_response, include_image_language }
);
};

Expand Down
4 changes: 3 additions & 1 deletion src/entities/v3/tv.js
Original file line number Diff line number Diff line change
Expand Up @@ -171,11 +171,12 @@ export const deleteRating = async (tvId, options = {}) => {
* @param {Object} options
* @param {string} options.language
* @param {string} options.append_to_response
* @param {string} options.include_image_language
* @returns {Promise}
* @see https://developers.themoviedb.org/3/tv/get-tv-details
*/
export const details = async (tvId, options = {}) => {
const { language, append_to_response } = options;
const { language, append_to_response, include_image_language } = options;

if (!tvId && tvId !== 0) {
return Promise.reject('A tvId has to be provided');
Expand All @@ -184,6 +185,7 @@ export const details = async (tvId, options = {}) => {
return await makeHttpRequest(urls.v3.TV_DETAILS.replace(':id', tvId), {
language,
append_to_response,
include_image_language,
});
};

Expand Down

0 comments on commit 4997224

Please sign in to comment.