From 19a9a6b40df2eb2e087139b1c1d1da24540de9da Mon Sep 17 00:00:00 2001 From: vi Date: Sun, 24 Aug 2014 14:00:27 +0800 Subject: [PATCH] Fixed Cookie parser -- fields and predicates were mismatched. --- src/Data/HTTPSEverywhere/Rules/Internal/Parser.hs | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/src/Data/HTTPSEverywhere/Rules/Internal/Parser.hs b/src/Data/HTTPSEverywhere/Rules/Internal/Parser.hs index 490e33b..8d5f34d 100644 --- a/src/Data/HTTPSEverywhere/Rules/Internal/Parser.hs +++ b/src/Data/HTTPSEverywhere/Rules/Internal/Parser.hs @@ -59,4 +59,4 @@ parseCookieRule :: Element -> Maybe CookieRule parseCookieRule element = CookieRule <$> do hostMatches <- element ^. attr "host" . to (>>= match) nameMatches <- element ^. attr "name" . to (>>= match) - return $ \Cookie{..} -> hostMatches (cs cookie_name) && nameMatches (cs cookie_domain) + return $ \Cookie{..} -> nameMatches (cs cookie_name) && hostMatches (cs cookie_domain)