{-This file is part of the Haskell package themoviedb. It is subject tothe license terms in the LICENSE file found in the top-level directoryof this distribution and at git://pmade.com/themoviedb/LICENSE. Nopart of themoviedb package, including this file, may be copied,modified, propagated, or distributed except according to the termscontained in the LICENSE file.-}module Network.API.TheMovieDB.Config (configErr, config) whereimport Network.API.TheMovieDB.Genericimport Network.API.TheMovieDB.Types-- | Fetch the API configuration information such as base URLs for-- movie posters. Results in either an 'Error' or a 'Configuration'.configErr :: Context -> IO (Either Error Configuration)configErr ctx = getAndParse ctx "configuration" []-- | Fetch the API configuration information or fail. For a function-- that returns an error instead of failing see 'configErr'.config :: Context -> IO Configurationconfig ctx = getOrFail $ configErr ctx