blob: a7bb136618f5e17b5d0f76e13f4053dbe68cc5bc (
plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
|
module Controller.User
( list
) where
import Control.Monad.IO.Class (liftIO)
import Web.Scotty (ActionM)
import qualified Web.Scotty as S
import qualified Model.Query as Query
import qualified Persistence.User as UserPersistence
import qualified Secure
list :: ActionM ()
list =
Secure.loggedAction (\_ ->
(liftIO . Query.run $ UserPersistence.list) >>= S.json
)
|