From 20f68b706c67dae142c394c55e233527f7bec2cf Mon Sep 17 00:00:00 2001 From: "Scott R. Parish" Date: Sat, 16 Jan 2010 18:33:32 -0600 Subject: [PATCH] rename curClose to finish a-la HDBC --- Database/MongoDB.hs | 7 ++++--- 1 file changed, 4 insertions(+), 3 deletions(-) diff --git a/Database/MongoDB.hs b/Database/MongoDB.hs index 9e146a6..095173e 100644 --- a/Database/MongoDB.hs +++ b/Database/MongoDB.hs @@ -2,7 +2,7 @@ module Database.MongoDB ( connect, connectOnPort, conClose, delete, insert, insertMany, query, remove, update, - nextDoc, curClose, + nextDoc, finish, Collection, FieldSelector, NumToSkip, NumToReturn, RequestID, Selector, Opcode(..), QueryOpt(..), @@ -281,8 +281,9 @@ getMore cur = do return $ Just doc -curClose :: Cursor -> IO () -curClose cur = do +{- Manually close a cursor -- usually not needed. -} +finish :: Cursor -> IO () +finish cur = do let h = cHandle $ curCon cur cid <- readIORef $ curID cur let body = runPut $ do