import { queryOMDb } from "@/api/omdb";
import MovieList from "../../common/components/MovieList";

export default async function SearchPage({
  queryParamString,
}: {
  queryParamString: string;
}) {

  const { Search } = await queryOMDb(queryParamString);
  const movies = Search || [];

  return (
      <MovieList movies={movies} />
  );
}
