aboutsummaryrefslogtreecommitdiff
path: root/compiler/src/Gallery.hs
diff options
context:
space:
mode:
authorpacien2019-12-26 08:03:31 +0100
committerpacien2019-12-26 08:03:31 +0100
commitaead07929e6ed13375b86539b1679a88993c9cf5 (patch)
treea3709043d1d27abb93479c9a0e199870acce3c55 /compiler/src/Gallery.hs
parent3cd1ed2ed39a31ed2c63e9e116edccd3d7946435 (diff)
downloadldgallery-aead07929e6ed13375b86539b1679a88993c9cf5.tar.gz
compiler: extract config and remove utils
Diffstat (limited to 'compiler/src/Gallery.hs')
-rw-r--r--compiler/src/Gallery.hs6
1 files changed, 5 insertions, 1 deletions
diff --git a/compiler/src/Gallery.hs b/compiler/src/Gallery.hs
index 3be62ad..ce52523 100644
--- a/compiler/src/Gallery.hs
+++ b/compiler/src/Gallery.hs
@@ -32,7 +32,8 @@ import Data.Maybe (fromMaybe)
32import Data.Aeson (ToJSON, genericToJSON, genericToEncoding) 32import Data.Aeson (ToJSON, genericToJSON, genericToEncoding)
33import qualified Data.Aeson as JSON 33import qualified Data.Aeson as JSON
34 34
35importĀ Utils 35import qualified Data.Set as Set
36
36import Files 37import Files
37import Input 38import Input
38import Resource 39import Resource
@@ -121,3 +122,6 @@ buildGalleryTree (DirResource dirItems path@(dirname:_) thumbnailPath) =
121 where 122 where
122 aggregateChildTags :: [GalleryItem] -> [Tag] 123 aggregateChildTags :: [GalleryItem] -> [Tag]
123 aggregateChildTags = unique . concatMap (\item -> tags (item::GalleryItem)) 124 aggregateChildTags = unique . concatMap (\item -> tags (item::GalleryItem))
125
126 unique :: Ord a => [a] -> [a]
127 unique = Set.toList . Set.fromList