Skip to content

Commit

Permalink
add GET to parseRequest
Browse files Browse the repository at this point in the history
  • Loading branch information
giantimi committed Jun 4, 2024
1 parent 838078d commit 795e9fe
Showing 1 changed file with 2 additions and 2 deletions.
4 changes: 2 additions & 2 deletions exec/TXG.hs
Original file line number Diff line number Diff line change
Expand Up @@ -706,12 +706,12 @@ loadContracts config (ChainwebHost h _p2p service) contractLoaders = do

queryCut :: Manager -> HostAddress -> ChainwebVersion -> IO (Either ApiError Cut)
queryCut mgr (HostAddress h p) version = do
let url = "https://" <> hostnameToText h <> ":" <> portToText p <> "/chainweb/0.0/" <> chainwebVersionToText version <> "/cut"
let url = "GET https://" <> hostnameToText h <> ":" <> portToText p <> "/chainweb/0.0/" <> chainwebVersionToText version <> "/cut"
req <- parseRequest $ T.unpack url
res <- handleRequest req mgr
case res of
Left err -> do
putStrLn $ "The url is :" <> (T.unpack url)
putStrLn $ "The url is : " <> T.unpack url
putStrLn $ "Error: " <> show err
pure $ Left err
Right response -> do
Expand Down

0 comments on commit 795e9fe

Please sign in to comment.