diff options
author | Jasper Van der Jeugt <jaspervdj@gmail.com> | 2009-12-25 12:06:11 +0100 |
---|---|---|
committer | Jasper Van der Jeugt <jaspervdj@gmail.com> | 2009-12-25 12:06:11 +0100 |
commit | a53235285878d4199947b368ea703c30adf74710 (patch) | |
tree | 1996e52dfba691dd57177f07832871fa484744e7 /src/Text/Hakyll | |
parent | 4fa472250e9041f95dc21adefcfd70cfefd09bc2 (diff) | |
download | hakyll-a53235285878d4199947b368ea703c30adf74710.tar.gz |
Some more tests. Fixed split function.
Diffstat (limited to 'src/Text/Hakyll')
-rw-r--r-- | src/Text/Hakyll/Util.hs | 3 |
1 files changed, 2 insertions, 1 deletions
diff --git a/src/Text/Hakyll/Util.hs b/src/Text/Hakyll/Util.hs index 6076dc4..7dc0ce3 100644 --- a/src/Text/Hakyll/Util.hs +++ b/src/Text/Hakyll/Util.hs @@ -25,4 +25,5 @@ stripHTML str = let (beforeTag, rest) = break (== '<') str -- | Split a list at a certain element. split :: String -> String -> [String] -split pattern = splitRegex (mkRegex pattern) +split pattern = filter (not . null) + . splitRegex (mkRegex pattern) |