client_session_key in config folder

This commit is contained in:
Michael Snoyman 2011-07-15 08:59:04 +03:00
parent 6f671dbd9b
commit 4d7519d2be
2 changed files with 7 additions and 0 deletions

View File

@ -68,6 +68,9 @@ mkYesodData "~sitearg~" $(parseRoutesFile "config/routes")
instance Yesod ~sitearg~ where
approot = Settings.appRoot . settings
-- Place the session key file in the config folder
encryptKey _ = fmap Just $ getKey "config/client_session_key.aes"
defaultLayout widget = do
mmsg <- getMessage
pc <- widgetToPageContent $ do

View File

@ -34,6 +34,7 @@ import qualified Data.Text.Lazy
import qualified Data.Text.Lazy.Encoding
import Text.Jasmine (minifym)
import qualified Data.Text as T
import Web.ClientSession (getKey)
-- | The site argument for your application. This can be a good place to
-- keep settings and values requiring initialization before your application
@ -79,6 +80,9 @@ mkYesodData "~sitearg~" $(parseRoutesFile "config/routes")
instance Yesod ~sitearg~ where
approot = Settings.appRoot . settings
-- Place the session key file in the config folder
encryptKey _ = fmap Just $ getKey "config/client_session_key.aes"
defaultLayout widget = do
mmsg <- getMessage
pc <- widgetToPageContent $ do