Skip to content

Commit

Permalink
fix compile error
Browse files Browse the repository at this point in the history
  • Loading branch information
konstantin-it-lysenko committed Dec 21, 2023
1 parent 7930fef commit 3eb1558
Showing 1 changed file with 3 additions and 3 deletions.
6 changes: 3 additions & 3 deletions src/pages/MovieDetails.jsx
Original file line number Diff line number Diff line change
Expand Up @@ -20,12 +20,12 @@ const MovieDetails = () => {

useEffect(() => {
if (!movieId) return;
getSelectedMovie(movieId);
getSelectedMovie();
}, [movieId]);

const getSelectedMovie = async id => {
const getSelectedMovie = async () => {
try {
const response = await getMovieById(id);
const response = await getMovieById(movieId);

setMovie(response);
} catch (err) {
Expand Down

0 comments on commit 3eb1558

Please sign in to comment.