diff options
| author | Mirek Kratochvil <exa.exa@gmail.com> | 2023-10-15 23:06:59 +0200 |
|---|---|---|
| committer | Mirek Kratochvil <miroslav.kratochvil@uni.lu> | 2023-10-16 11:34:26 +0200 |
| commit | 1f2ab58478925481d5cf273d38e30fc06e96e69e (patch) | |
| tree | 9f65d867623fe1dfa48b856c0740bc1e2334c509 /reploy.hs | |
| parent | 53aa481aace0a59579846fddba8de41a465654ea (diff) | |
| download | reploy-1f2ab58478925481d5cf273d38e30fc06e96e69e.tar.gz reploy-1f2ab58478925481d5cf273d38e30fc06e96e69e.tar.bz2 | |
stabilize and parametrize sorting of stuff, get rid of "title"
Diffstat (limited to 'reploy.hs')
| -rw-r--r-- | reploy.hs | 6 |
1 files changed, 3 insertions, 3 deletions
@@ -439,8 +439,8 @@ makeSearchData :: FilePath -> PageInfo -> Site [Y.Value] makeSearchData mount pi = do link <- rootedPageLink mount text <- io . runIOorExplode $ writePlain plainWriteOpts (pi ^. pageDoc) - let title = pi ^? pageMeta . key "title" . _String - -- TODO: unify retrieval of tags + let name = pi ^? pageMeta . key "name" . _String + -- TODO: unify retrieval of tags? let tags = sort $ pi ^.. pageMeta . key "tags" . values . _String . to T.unpack tagnames <- traverse (traverse getTagGroupName . inits . splitTag) tags @@ -450,7 +450,7 @@ makeSearchData mount pi = do else pure $ [ Y.object [ ("link", fromString link) - , ("title", maybe (fromString mount) Y.String title) + , ("name", maybe (fromString mount) Y.String name) , ("tags", tagarray) , ("text", Y.String text) ] |
