mirror of
https://github.com/Ernous/TorrServerJellyfin.git
synced 2025-12-19 21:46:11 +05:00
@@ -129,7 +129,7 @@ export default function AddDialog({ handleClose }) {
|
|||||||
useEffect(() => {
|
useEffect(() => {
|
||||||
// if title exists and title was changed then search poster.
|
// if title exists and title was changed then search poster.
|
||||||
const titleChanged = title !== prevTitleState
|
const titleChanged = title !== prevTitleState
|
||||||
if (!titleChanged) return
|
if (!titleChanged || !title) return
|
||||||
|
|
||||||
if (skipDebounce) {
|
if (skipDebounce) {
|
||||||
posterSearch(title, posterSearchLanguage)
|
posterSearch(title, posterSearchLanguage)
|
||||||
|
|||||||
@@ -1,7 +1,6 @@
|
|||||||
import axios from 'axios'
|
import axios from 'axios'
|
||||||
|
|
||||||
export const getMoviePosters = (movieName, language = 'en') => {
|
export const getMoviePosters = (movieName, language = 'en') => {
|
||||||
if (!movieName) return new Promise(resolve => resolve(null))
|
|
||||||
const request = `${`http://api.themoviedb.org/3/search/multi?api_key=${process.env.REACT_APP_TMDB_API_KEY}`}&language=${language}&include_image_language=${language},null&query=${movieName}`
|
const request = `${`http://api.themoviedb.org/3/search/multi?api_key=${process.env.REACT_APP_TMDB_API_KEY}`}&language=${language}&include_image_language=${language},null&query=${movieName}`
|
||||||
|
|
||||||
return axios
|
return axios
|
||||||
|
|||||||
Reference in New Issue
Block a user