diff --git a/src/Vervis/Handler/Cloth.hs b/src/Vervis/Handler/Cloth.hs index 187fc0a..621168a 100644 --- a/src/Vervis/Handler/Cloth.hs +++ b/src/Vervis/Handler/Cloth.hs @@ -437,7 +437,7 @@ getBundleR loomHash clothHash bundleHash = do bundleID <- decodeKeyHashid404 bundleHash bundle <- get404 bundleID unless (bundleTicket bundle == clothID) notFound - latest :| prevs <- + latest :| olds <- case justHere proposal of Nothing -> error "Why didn't getCloth find any bundles" Just bundles -> return bundles @@ -448,8 +448,8 @@ getBundleR loomHash clothHash bundleHash = do Just ne -> return ne let (prevs, mcurr) = if bundleID == latest - then (prevs, Nothing) - else ([] , Just latest) + then (olds, Nothing) + else ([] , Just latest) return (patches, prevs, mcurr) encodeRouteLocal <- getEncodeRouteLocal