Merge pull request #348 from meteficha/yesod-static-fix

yesod-static: Correctly add the "etag" param to TH-generated routes.
This commit is contained in:
Greg Weber 2012-05-19 08:43:10 -07:00
commit 13c4e137a2

View File

@ -307,7 +307,7 @@ mkStaticFilesList fp fs routeConName makeHash = do
pack' <- [|pack|]
qs <- if makeHash
then do hash <- qRunIO $ base64md5File $ pathFromRawPieces fp f
[|[(pack $(lift hash), mempty)]|]
[|[("etag" :: Text, pack $(lift hash))]|]
else return $ ListE []
return
[ SigD routeName $ ConT route