diff --git a/Yesod/Helpers/Auth/OAuth.hs b/Yesod/Helpers/Auth/OAuth.hs index 06836f28..a2c6c438 100644 --- a/Yesod/Helpers/Auth/OAuth.hs +++ b/Yesod/Helpers/Auth/OAuth.hs @@ -56,7 +56,7 @@ authOAuth name ident reqUrl accUrl authUrl key sec = AuthPlugin name dispatch lo oaTok <- runFormGet' $ stringInput "oauth_token" let reqTok = Credential [ ("oauth_verifier", pack verifier), ("oauth_token", pack oaTok) ] - accTok <- liftIO $ getTokenCredential oauth reqTok + accTok <- liftIO $ getAccessToken oauth reqTok let crId = unpack $ fromJust $ lookup (pack ident) $ unCredential accTok creds = Creds name crId $ map (unpack *** unpack) $ unCredential accTok setCreds True creds @@ -84,4 +84,4 @@ authTwitter = authOAuth "twitter" "http://twitter.com/oauth/authorize" twitterUrl :: AuthRoute -twitterUrl = oauthUrl "twitter" \ No newline at end of file +twitterUrl = oauthUrl "twitter" diff --git a/yesod-auth.cabal b/yesod-auth.cabal index f7ad7833..9f1d0308 100644 --- a/yesod-auth.cabal +++ b/yesod-auth.cabal @@ -13,17 +13,13 @@ homepage: http://docs.yesodweb.com/ flag ghc7 -flag authenticate-oauth-supported - Description: Whether authenticate package supports OAuth or not. - Default: False - library if flag(ghc7) build-depends: base >= 4.3 && < 5 cpp-options: -DGHC7 else build-depends: base >= 4 && < 4.3 - build-depends: authenticate >= 0.8 && < 0.9 + build-depends: authenticate >= 0.8.1 && < 0.9 , bytestring >= 0.9.1.4 && < 0.10 , yesod-core >= 0.7 && < 0.8 , wai >= 0.3 && < 0.4 @@ -47,11 +43,6 @@ library , SHA >= 1.4.1.3 && < 1.5 , http-enumerator >= 0.3.1 && < 0.4 - if flag(authenticate-oauth-supported) - build-depends: authenticate >= 0.8.0.1 && < 0.9 - else - build-depends: authenticate-oauth >= 0.1 && < 0.2 - exposed-modules: Yesod.Helpers.Auth Yesod.Helpers.Auth.Dummy Yesod.Helpers.Auth.Email