1. Luke Plant
  2. haskellblog

Commits

Luke Plant  committed 56e4b96

small tidyup

  • Participants
  • Parent commits d9bb1fe
  • Branches default

Comments (0)

Files changed (1)

File src/Migrate.hs

View file
  • Ignore whitespace
 -- padding columns to specified amount
 readTable :: FilePath -> Int -> IO [[String]]
 readTable filename cols = do f <- readFile filename
-                             let lines = splitRows f
-                                 lines' = filter (/= "") lines
-                                 arr = map (padCols . splitCols) lines'
+                             let lines = filter (/= "") $ splitRows f
+                                 arr = map (padCols . splitCols) lines
                              return arr
     where 
       splitRows s = split s '\n'