Permalink
Browse files

Simplify the 'insertClient' function

  • Loading branch information...
adomokos committed Dec 5, 2017
1 parent 841959b commit 2dac1bc5f175d6e14bd040ffe5a0858042a688ea
Showing with 1 addition and 4 deletions.
  1. +1 −4 app/Main.hs
View
@@ -37,10 +37,7 @@ withConn f = do
insertClient :: String -> String -> IO ()
insertClient name subdomain = do
clientId <-
withConn (\conn -> do
insertClientSQL name subdomain conn
)
clientId <- withConn $ do insertClientSQL name subdomain
putStrLn $ "New client's id is " ++ show clientId
countClient :: IO ()

0 comments on commit 2dac1bc

Please sign in to comment.