Skip to content

Commit a226009

Browse files
authored
Add Functor instance to AuthHandler. (#1638)
1 parent b8675c0 commit a226009

File tree

2 files changed

+4
-1
lines changed
  • changelog.d
  • servant-server/src/Servant/Server/Experimental

2 files changed

+4
-1
lines changed

changelog.d/1638

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,2 @@
1+
synopsis: Add Functor instance to AuthHandler.
2+
prs: #1638

servant-server/src/Servant/Server/Experimental/Auth.hs

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,6 @@
11
{-# OPTIONS_GHC -fno-warn-orphans #-}
22
{-# LANGUAGE DeriveDataTypeable #-}
3+
{-# LANGUAGE DeriveFunctor #-}
34
{-# LANGUAGE DeriveGeneric #-}
45
{-# LANGUAGE FlexibleContexts #-}
56
{-# LANGUAGE FlexibleInstances #-}
@@ -44,7 +45,7 @@ type family AuthServerData a :: *
4445
-- NOTE: THIS API IS EXPERIMENTAL AND SUBJECT TO CHANGE
4546
newtype AuthHandler r usr = AuthHandler
4647
{ unAuthHandler :: r -> Handler usr }
47-
deriving (Generic, Typeable)
48+
deriving (Functor, Generic, Typeable)
4849

4950
-- | NOTE: THIS API IS EXPERIMENTAL AND SUBJECT TO CHANGE
5051
mkAuthHandler :: (r -> Handler usr) -> AuthHandler r usr

0 commit comments

Comments
 (0)