diff options
author | Kjetil Orbekk <kjetil.orbekk@gmail.com> | 2015-10-15 21:24:00 -0400 |
---|---|---|
committer | Kjetil Orbekk <kjetil.orbekk@gmail.com> | 2015-10-15 21:24:00 -0400 |
commit | 093d277aea8ae9fb423d58a45849a84f0d75b58a (patch) | |
tree | 866d60936077219f199b52ea4c69583328130583 | |
parent | c32c97d6907d8b69e5d651bc44831001fffcfda0 (diff) |
Hide albums that start with ".".
-rw-r--r-- | src/PhotoStore.hs | 4 |
1 files changed, 1 insertions, 3 deletions
diff --git a/src/PhotoStore.hs b/src/PhotoStore.hs index ead129a..c6c043e 100644 --- a/src/PhotoStore.hs +++ b/src/PhotoStore.hs @@ -24,9 +24,7 @@ data Config = Config getDirectoryFiles path = getDirectoryContents path >>= return . filter f where f filename = not (filename `elem` [".", ".."]) -validAlbumName name = - name /= "." - && name /= ".." +validAlbumName name = not ("." `isPrefixOf` name) getAlbums :: Config -> IO [Album] getAlbums config = do |