From 78774e835ac0c564cf52a5e6dd0bf22b56761c4d Mon Sep 17 00:00:00 2001 From: Ben Sima Date: Mon, 1 Jun 2020 22:22:13 -0700 Subject: Initialize Hero database --- Biz/Ibb/Keep.hs | 5 +++-- 1 file changed, 3 insertions(+), 2 deletions(-) (limited to 'Biz') diff --git a/Biz/Ibb/Keep.hs b/Biz/Ibb/Keep.hs index 8ee1228..c7dabb0 100644 --- a/Biz/Ibb/Keep.hs +++ b/Biz/Ibb/Keep.hs @@ -11,6 +11,7 @@ -- like `$(keep ''MyType)`. module Biz.Ibb.Keep where +import Alpha import Biz.Ibb.Core (Book (..), Person (..)) import qualified Biz.Ibb.Influencers as Influencers import Control.Monad.Reader (ask) @@ -61,7 +62,7 @@ instance Indexable Person where -- | updates the `IbbKeep` with a new `Person` newPerson :: Text -> Text -> Update IbbKeep Person newPerson name blurb = do - k <- get + keep <- get put $ k { _people = IxSet.insert p (_people k) @@ -79,7 +80,7 @@ newPerson name blurb = do } getPeople :: Int -> Acid.Query IbbKeep [Person] -getPeople n = take n $ IxSet.toList $ _people keep _people /> IxSet.toList /> take n -- * Index @Book@ -- cgit v1.2.3