diff --git a/app/Main.hs b/app/Main.hs index b051aa1..77e7d43 100644 --- a/app/Main.hs +++ b/app/Main.hs @@ -8,11 +8,8 @@ module Main where import Data.ByteString.Lazy as BS import Data.List as List -import Data.Text as T import Debug.Trace (traceShow) import Track (parseBS, parseFile) --- import Import - import Yesod.Core import Yesod.Form.Fields import Yesod.Form.Functions @@ -41,7 +38,7 @@ instance Yesod Souplesse getCalendarR :: Handler Html getCalendarR = do - (formWidget, formEnctype) <- generateFormPost uploadForm + (formWidget, _) <- generateFormPost uploadForm defaultLayout [whamlet|

Calendar @@ -92,14 +89,14 @@ instance RenderMessage Souplesse FormMessage where postUploadR :: Handler Html postUploadR = do - ((result, widget), enctype) <- runFormPost uploadForm + ((result, _), _) <- runFormPost uploadForm case result of FormSuccess upload -> do bs <- fileSourceByteString $ fileInfo upload case Track.parseBS (fromStrict bs) of Right points -> defaultLayout [whamlet|

#{List.length points} points - thanks!|] - Left e -> + Left _ -> defaultLayout [whamlet|

parse error ] FormMissing ->