uppercase everywhere

This commit is contained in:
Ding 2024-05-24 23:57:38 +08:00
parent 2c892977cc
commit 6c1f627067
2 changed files with 4 additions and 4 deletions

View File

@ -150,7 +150,7 @@ mkFoundation = do
, loadPlugin (oauth2Spotify []) "SPOTIFY"
, loadPlugin oauth2Twitch "TWITCH"
, loadPlugin oauth2WordPressDotCom "WORDPRESS_DOT_COM"
, loadPlugin oauth2Orcid "ORCID"
, loadPlugin oauth2ORCID "ORCID"
, loadPlugin oauth2Upcase "UPCASE"
]

View File

@ -1,7 +1,7 @@
{-# LANGUAGE OverloadedStrings #-}
module Yesod.Auth.OAuth2.ORCID
( oauth2Orcid
( oauth2ORCID
) where
import qualified Data.Text as T
@ -15,14 +15,14 @@ newtype User = User Text
instance FromJSON User where
parseJSON = withObject "User" $ \o -> User <$> o .: "sub"
oauth2Orcid
oauth2ORCID
:: YesodAuth m
=> Text
-- ^ Client Id
-> Text
-- ^ Client Secret
-> AuthPlugin m
oauth2Orcid clientId clientSecret =
oauth2ORCID clientId clientSecret =
authOAuth2 pluginName oauth2 $ \manager token -> do
(User userId, userResponse) <-
authGetProfile