1 diff -Naur dtwitzen-0.2/Request.hs dtwitzen-0.2/Request.hs
2 --- dtwitzen-0.2/Request.hs 2008-08-10 07:38:59.000000000 +0300
3 +++ dtwitzen-0.2/Request.hs 2009-09-08 14:00:59.741501368 +0300
5 import System.Environment
11 data Account = MkAccount { acUsername :: String
16 -reqTimeline :: Account -> IO (Result Response)
17 -reqTimeline = httpRequest . mkRequest
18 +reqTimeline :: Account -> IO (Result (Response String))
19 +reqTimeline = httpRequest . mkTwitterRequest
21 -mkRequest :: Account -> (Request, Account)
22 -mkRequest ac = (Request { rqURI = uri
23 +mkTwitterRequest :: Account -> (Request String, Account)
24 +mkTwitterRequest ac = (Request { rqURI = uri
26 , rqHeaders = [Header HdrHost "twitter.com"]
29 where uri = fromJust $ parseURI $ "http://twitter.com/statuses/friends_timeline/"++(acUsername ac)++".xml"
31 -httpRequest :: (Request, Account) -> IO (Result Response)
32 +httpRequest :: (Request String, Account) -> IO (Result (Response String))
33 httpRequest (req,account)