diff --git a/src/Database/PostgreSQL/Simple/Migration.hs b/src/Database/PostgreSQL/Simple/Migration.hs index d3c333f..c9f04a4 100644 --- a/src/Database/PostgreSQL/Simple/Migration.hs +++ b/src/Database/PostgreSQL/Simple/Migration.hs @@ -12,6 +12,9 @@ -- For usage, see Readme.markdown. {-# LANGUAGE CPP #-} +{-# LANGUAGE DeriveFoldable #-} +{-# LANGUAGE DeriveFunctor #-} +{-# LANGUAGE DeriveTraversable #-} {-# LANGUAGE LambdaCase #-} {-# LANGUAGE OverloadedStrings #-} @@ -41,6 +44,8 @@ import Control.Monad (void, when) import qualified Crypto.Hash.MD5 as MD5 (hash) import qualified Data.ByteString as BS (ByteString, readFile) import qualified Data.ByteString.Base64 as B64 (encode) +import Data.Foldable (Foldable) +import Data.Traversable (Traversable) import Data.List (isPrefixOf, sort) #if __GLASGOW_HASKELL__ < 710 import Data.Monoid (mconcat) @@ -242,7 +247,7 @@ data MigrationResult a -- ^ There was an error in script migration. | MigrationSuccess -- ^ All scripts have been executed successfully. - deriving (Show, Eq, Read, Ord) + deriving (Show, Eq, Read, Ord, Functor, Foldable, Traversable) -- | The 'MigrationContext' provides an execution context for migrations. data MigrationContext = MigrationContext