diff --git a/yesod/scaffold/Application.hs.cg b/yesod/scaffold/Application.hs.cg index 46758e1d..3c60a604 100644 --- a/yesod/scaffold/Application.hs.cg +++ b/yesod/scaffold/Application.hs.cg @@ -1,6 +1,5 @@ {-# LANGUAGE TemplateHaskell #-} {-# LANGUAGE MultiParamTypeClasses #-} -{-# LANGUAGE OverloadedStrings #-} {-# LANGUAGE CPP #-} {-# OPTIONS_GHC -fno-warn-orphans #-} module Application @@ -14,6 +13,7 @@ import Yesod.Static import Yesod.Auth import Yesod.Default.Config import Yesod.Default.Main +import Yesod.Default.Handlers import Yesod.Logger (Logger) import Data.ByteString (ByteString) import Data.Dynamic (Dynamic, toDyn) @@ -27,14 +27,6 @@ import Handler.Root -- the comments there for more details. mkYesodDispatch "~sitearg~" resources~sitearg~ --- Some default handlers that ship with the Yesod site template. You will --- very rarely need to modify this. -getFaviconR :: Handler () -getFaviconR = sendFile "image/x-icon" "config/favicon.ico" - -getRobotsR :: Handler RepPlain -getRobotsR = return $ RepPlain $ toContent ("User-agent: *" :: ByteString) - -- This function allocates resources (such as a database connection pool), -- performs initialization and creates a WAI application. This is also the -- place to put your migrate statements to have automatic database diff --git a/yesod/scaffold/tiny/Application.hs.cg b/yesod/scaffold/tiny/Application.hs.cg index 5142288d..110747bc 100644 --- a/yesod/scaffold/tiny/Application.hs.cg +++ b/yesod/scaffold/tiny/Application.hs.cg @@ -1,6 +1,5 @@ {-# LANGUAGE TemplateHaskell #-} {-# LANGUAGE MultiParamTypeClasses #-} -{-# LANGUAGE OverloadedStrings #-} {-# LANGUAGE CPP #-} {-# OPTIONS_GHC -fno-warn-orphans #-} module Application @@ -13,6 +12,7 @@ import Settings import Yesod.Static import Yesod.Default.Config import Yesod.Default.Main (defaultDevelApp, defaultRunner) +import Yesod.Default.Handlers (getFaviconR, getRobotsR) import Yesod.Logger (Logger) import Data.ByteString (ByteString) import Network.Wai (Application) @@ -26,14 +26,6 @@ import Handler.Root -- the comments there for more details. mkYesodDispatch "~sitearg~" resources~sitearg~ --- Some default handlers that ship with the Yesod site template. You will --- very rarely need to modify this. -getFaviconR :: Handler () -getFaviconR = sendFile "image/x-icon" "config/favicon.ico" - -getRobotsR :: Handler RepPlain -getRobotsR = return $ RepPlain $ toContent ("User-agent: *" :: ByteString) - -- This function allocates resources (such as a database connection pool), -- performs initialization and creates a WAI application. This is also the -- place to put your migrate statements to have automatic database