Source

riak-haskell-client / src / Network / Riak / Response.hs

Diff from to

File src/Network/Riak/Response.hs

 import Network.Riak.Protocol.ListBucketsResponse
 import Network.Riak.Protocol.PutResponse
 import Network.Riak.Types.Internal hiding (MessageTag(..))
+import qualified Network.Riak.Protocol.Link as Link
 import qualified Data.ByteString.Lazy as L
 import qualified Data.Sequence as Seq
 
 -- | Construct a get response.  Bucket and key names in links are
 -- URL-unescaped.
 get :: Maybe GetResponse -> Maybe (Seq.Seq Content, VClock)
-get (Just (GetResponse content (Just vclock)))
+get (Just (GetResponse content (Just vclock) _))
       = Just (unescapeLinks <$> content, VClock vclock)
 get _ = Nothing
 {-# INLINE get #-}
 -- 'Content' value.
 unescapeLinks :: Content -> Content
 unescapeLinks c = c { links = go <$> links c }
-  where go l = l { bucket = unescape <$> bucket l, key = unescape <$> key l }
+  where go l = l { bucket = unescape <$> bucket l
+                 , Link.key = unescape <$> Link.key l }