One more sort for #1684
This commit is contained in:
parent
084a3cefb5
commit
7964967ba8
@ -71,7 +71,7 @@ import Data.FileEmbed (embedDir)
|
|||||||
import Yesod.Core
|
import Yesod.Core
|
||||||
import Yesod.Core.Types
|
import Yesod.Core.Types
|
||||||
|
|
||||||
import Data.List (intercalate)
|
import Data.List (intercalate, sort)
|
||||||
import Language.Haskell.TH
|
import Language.Haskell.TH
|
||||||
import Language.Haskell.TH.Syntax as TH
|
import Language.Haskell.TH.Syntax as TH
|
||||||
|
|
||||||
@ -192,7 +192,7 @@ getFileListPieces = flip evalStateT M.empty . flip go id
|
|||||||
-> ([String] -> [String])
|
-> ([String] -> [String])
|
||||||
-> StateT (M.Map String String) IO [[String]]
|
-> StateT (M.Map String String) IO [[String]]
|
||||||
go fp front = do
|
go fp front = do
|
||||||
allContents <- liftIO $ filter notHidden `fmap` getDirectoryContents fp
|
allContents <- liftIO $ (sort . filter notHidden) `fmap` getDirectoryContents fp
|
||||||
let fullPath :: String -> String
|
let fullPath :: String -> String
|
||||||
fullPath f = fp ++ '/' : f
|
fullPath f = fp ++ '/' : f
|
||||||
files <- liftIO $ filterM (doesFileExist . fullPath) allContents
|
files <- liftIO $ filterM (doesFileExist . fullPath) allContents
|
||||||
|
|||||||
Loading…
Reference in New Issue
Block a user