Merge branch 'update-persistent' of https://github.com/DanBurton/yesod
This commit is contained in:
commit
aed169b43f
@ -1,3 +1,7 @@
|
|||||||
|
## 1.6.0.1
|
||||||
|
|
||||||
|
* Compile with GHC 8.6 [#1561](https://github.com/yesodweb/yesod/pull/1561)
|
||||||
|
|
||||||
## 1.6.0
|
## 1.6.0
|
||||||
|
|
||||||
* Upgrade to yesod-core 1.6.0
|
* Upgrade to yesod-core 1.6.0
|
||||||
|
|||||||
@ -1,5 +1,6 @@
|
|||||||
{-# LANGUAGE DeriveDataTypeable, OverloadedStrings, QuasiQuotes #-}
|
{-# LANGUAGE DeriveDataTypeable, OverloadedStrings, QuasiQuotes #-}
|
||||||
{-# LANGUAGE FlexibleContexts #-}
|
{-# LANGUAGE FlexibleContexts #-}
|
||||||
|
{-# LANGUAGE LambdaCase #-}
|
||||||
{-# LANGUAGE RankNTypes #-}
|
{-# LANGUAGE RankNTypes #-}
|
||||||
{-# LANGUAGE GADTs #-}
|
{-# LANGUAGE GADTs #-}
|
||||||
{-# LANGUAGE ScopedTypeVariables #-}
|
{-# LANGUAGE ScopedTypeVariables #-}
|
||||||
@ -69,7 +70,9 @@ authOAuth oauth mkCreds = AuthPlugin name dispatch login
|
|||||||
setSession oauthSessionName $ lookupTokenSecret tok
|
setSession oauthSessionName $ lookupTokenSecret tok
|
||||||
redirect $ authorizeUrl oauth' tok
|
redirect $ authorizeUrl oauth' tok
|
||||||
dispatch "GET" [] = do
|
dispatch "GET" [] = do
|
||||||
Just tokSec <- lookupSession oauthSessionName
|
tokSec <- lookupSession oauthSessionName >>= \case
|
||||||
|
Just t -> return t
|
||||||
|
Nothing -> liftIO $ fail "lookupSession could not find session"
|
||||||
deleteSession oauthSessionName
|
deleteSession oauthSessionName
|
||||||
reqTok <-
|
reqTok <-
|
||||||
if oauthVersion oauth == OAuth10
|
if oauthVersion oauth == OAuth10
|
||||||
|
|||||||
@ -1,5 +1,5 @@
|
|||||||
name: yesod-auth-oauth
|
name: yesod-auth-oauth
|
||||||
version: 1.6.0
|
version: 1.6.0.1
|
||||||
license: BSD3
|
license: BSD3
|
||||||
license-file: LICENSE
|
license-file: LICENSE
|
||||||
author: Hiromi Ishii
|
author: Hiromi Ishii
|
||||||
|
|||||||
@ -2,7 +2,7 @@
|
|||||||
|
|
||||||
## 1.6.5
|
## 1.6.5
|
||||||
|
|
||||||
* Add support for persistent 2.9 [#1516](https://github.com/yesodweb/yesod/pull/1516)
|
* Add support for persistent 2.9 [#1516](https://github.com/yesodweb/yesod/pull/1516), [#1561](https://github.com/yesodweb/yesod/pull/1561)
|
||||||
|
|
||||||
## 1.6.4.1
|
## 1.6.4.1
|
||||||
|
|
||||||
|
|||||||
@ -1,6 +1,6 @@
|
|||||||
## 1.6.1
|
## 1.6.0.1
|
||||||
|
|
||||||
* Add support for persistent 2.9 [#1516](https://github.com/yesodweb/yesod/pull/1516)
|
* Add support for persistent 2.9 [#1516](https://github.com/yesodweb/yesod/pull/1516), [#1561](https://github.com/yesodweb/yesod/pull/1561)
|
||||||
|
|
||||||
## 1.6.0
|
## 1.6.0
|
||||||
|
|
||||||
|
|||||||
@ -1,5 +1,5 @@
|
|||||||
name: yesod-persistent
|
name: yesod-persistent
|
||||||
version: 1.6.1
|
version: 1.6.0.1
|
||||||
license: MIT
|
license: MIT
|
||||||
license-file: LICENSE
|
license-file: LICENSE
|
||||||
author: Michael Snoyman <michael@snoyman.com>
|
author: Michael Snoyman <michael@snoyman.com>
|
||||||
|
|||||||
@ -1,3 +1,7 @@
|
|||||||
|
## 1.6.0.1
|
||||||
|
|
||||||
|
* Make test suite build with GHC 8.6 [#1561](https://github.com/yesodweb/yesod/pull/1561)
|
||||||
|
|
||||||
## 1.6.0
|
## 1.6.0
|
||||||
|
|
||||||
* Upgrade to yesod-core 1.6.0
|
* Upgrade to yesod-core 1.6.0
|
||||||
|
|||||||
@ -1,4 +1,5 @@
|
|||||||
{-# LANGUAGE TemplateHaskell, QuasiQuotes, TypeFamilies, OverloadedStrings #-}
|
{-# LANGUAGE TemplateHaskell, QuasiQuotes, TypeFamilies, OverloadedStrings #-}
|
||||||
|
{-# LANGUAGE LambdaCase #-}
|
||||||
module EmbedProductionTest where
|
module EmbedProductionTest where
|
||||||
|
|
||||||
-- Tests the production mode of the embedded static subsite by
|
-- Tests the production mode of the embedded static subsite by
|
||||||
@ -108,7 +109,9 @@ embedProductionSpecs = yesodSpec (MyApp eProduction) $ do
|
|||||||
yit "Embedded Javascript" $ do
|
yit "Embedded Javascript" $ do
|
||||||
get HomeR
|
get HomeR
|
||||||
statusIs 200
|
statusIs 200
|
||||||
[script] <- htmlQuery "script"
|
script <- htmlQuery "script" >>= \case
|
||||||
|
[s] -> return s
|
||||||
|
_ -> liftIO $ fail "Expected singleton list of script"
|
||||||
let src = BL.takeWhile (/= 34) $ BL.drop 1 $ BL.dropWhile (/= 34) script -- 34 is "
|
let src = BL.takeWhile (/= 34) $ BL.drop 1 $ BL.dropWhile (/= 34) script -- 34 is "
|
||||||
|
|
||||||
get $ TL.toStrict $ TL.decodeUtf8 src
|
get $ TL.toStrict $ TL.decodeUtf8 src
|
||||||
|
|||||||
@ -1,5 +1,5 @@
|
|||||||
name: yesod-static
|
name: yesod-static
|
||||||
version: 1.6.0
|
version: 1.6.0.1
|
||||||
license: MIT
|
license: MIT
|
||||||
license-file: LICENSE
|
license-file: LICENSE
|
||||||
author: Michael Snoyman <michael@snoyman.com>
|
author: Michael Snoyman <michael@snoyman.com>
|
||||||
|
|||||||
@ -1,3 +1,7 @@
|
|||||||
|
## 1.6.5.1
|
||||||
|
|
||||||
|
* Make test suite build with GHC 8.6 [#1561](https://github.com/yesodweb/yesod/pull/1561)
|
||||||
|
|
||||||
## 1.6.5
|
## 1.6.5
|
||||||
bodyEquals prints out actual body in addition to expected body in failure msg
|
bodyEquals prints out actual body in addition to expected body in failure msg
|
||||||
[#1525](https://github.com/yesodweb/yesod/pull/1525)
|
[#1525](https://github.com/yesodweb/yesod/pull/1525)
|
||||||
|
|||||||
@ -5,6 +5,7 @@
|
|||||||
{-# LANGUAGE ScopedTypeVariables #-}
|
{-# LANGUAGE ScopedTypeVariables #-}
|
||||||
{-# LANGUAGE CPP #-}
|
{-# LANGUAGE CPP #-}
|
||||||
{-# LANGUAGE MultiParamTypeClasses #-}
|
{-# LANGUAGE MultiParamTypeClasses #-}
|
||||||
|
{-# LANGUAGE LambdaCase #-}
|
||||||
{-# LANGUAGE TemplateHaskell #-}
|
{-# LANGUAGE TemplateHaskell #-}
|
||||||
{-# LANGUAGE QuasiQuotes #-}
|
{-# LANGUAGE QuasiQuotes #-}
|
||||||
{-# LANGUAGE TypeFamilies #-}
|
{-# LANGUAGE TypeFamilies #-}
|
||||||
@ -482,8 +483,10 @@ postHomeR = defaultLayout
|
|||||||
|
|
||||||
postResourcesR :: Handler ()
|
postResourcesR :: Handler ()
|
||||||
postResourcesR = do
|
postResourcesR = do
|
||||||
([("foo", t)], _) <- runRequestBody
|
t <- runRequestBody >>= \case
|
||||||
sendResponseCreated $ ResourceR t
|
([("foo", t)], _) -> return t
|
||||||
|
_ -> liftIO $ fail "postResourcesR pattern match failure"
|
||||||
|
sendResponseCreated $ ResourceR t
|
||||||
|
|
||||||
getResourceR :: Text -> Handler Html
|
getResourceR :: Text -> Handler Html
|
||||||
getResourceR i = defaultLayout
|
getResourceR i = defaultLayout
|
||||||
|
|||||||
@ -1,5 +1,5 @@
|
|||||||
name: yesod-test
|
name: yesod-test
|
||||||
version: 1.6.5
|
version: 1.6.5.1
|
||||||
license: MIT
|
license: MIT
|
||||||
license-file: LICENSE
|
license-file: LICENSE
|
||||||
author: Nubis <nubis@woobiz.com.ar>
|
author: Nubis <nubis@woobiz.com.ar>
|
||||||
|
|||||||
Loading…
Reference in New Issue
Block a user