switch :: Config -> Application
switch cfg req
  | pathInfo req == [] = index cfg req
  | pathInfo req == ["point.json"] = point cfg req
  | otherwise = static req
switch :: Config -> Application
switch cfg req
  | pathInfo req == [] = index cfg req
  | pathInfo req == ["point.json"] = point cfg req
  | otherwise = static req
switch cfg req
  | pathInfo req == [] = index cfg req
  | pathInfo req == ["point.json"] = point cfg req
  | otherwise = static req