on master help sign in
Merge branch 'maintain/1.4'
commitb9eef250bd99049f98cd989f0838d9c50d880f50 authorMichael Snoyman <michael@snoyman.com> dateTue 10 Dec 2013, 09:26 (13 years ago) parent9a715a7386390f
1 file changed+2−2
wai-app-static/WaiAppStatic/Storage/Embedded/Runtime.hs+2−2
wai-app-static/WaiAppStatic/Storage/Embedded/Runtime.hs+2−2
@@ -19,7 +19,7 @@ import qualified Crypto.Classes as CR
1919import Crypto.Hash.CryptoAPI (hash', MD5)
2020import qualified Data.ByteString.Base64 as B64
2121import WaiAppStatic.Storage.Filesystem (defaultFileServerSettings)
22−import System.FilePath (pathSeparator)
22+import System.FilePath (isPathSeparator)
2323
2424-- | Serve the list of path/content pairs directly from memory.
2525embeddedSettings :: [(Prelude.FilePath, ByteString)] -> StaticSettings
@@ -68,7 +68,7 @@ toEmbedded fps =
6868 --
6969 -- We want to separate on the forward slash on *all* OSes, and on
7070 -- Windows, also separate on a backslash.
71− let (y, z) = break (\c -> c == '/' || c == pathSeparator) x
71+ let (y, z) = break isPathSeparator x
7272 in unsafeToPiece (T.pack y) : toPieces' (drop 1 z)
7373
7474 go :: [(Pieces, ByteString)] -> Embedded