diff options
Diffstat (limited to 'services/tazblog/src/RSS.hs')
-rw-r--r-- | services/tazblog/src/RSS.hs | 14 |
1 files changed, 7 insertions, 7 deletions
diff --git a/services/tazblog/src/RSS.hs b/services/tazblog/src/RSS.hs index 5d2340d5292f..02a2aafda969 100644 --- a/services/tazblog/src/RSS.hs +++ b/services/tazblog/src/RSS.hs @@ -5,7 +5,7 @@ import qualified Data.Text as T import Control.Monad (liftM) import Data.Maybe (fromMaybe) -import Data.Time (UTCTime, getCurrentTime) +import Data.Time (UTCTime(..), getCurrentTime, secondsToDiffTime) import Network.URI import Text.RSS @@ -13,11 +13,11 @@ import BlogStore import Locales createChannel :: BlogLang -> UTCTime -> [ChannelElem] -createChannel l now = [ Language $ show l - , Copyright "Vincent Ambo" - , WebMaster "tazjin@gmail.com" - , ChannelPubDate now - ] +createChannel l now = [ Language $ show l + , Copyright "Vincent Ambo" + , WebMaster "tazjin@gmail.com" + , ChannelPubDate now + ] createRSS :: BlogLang -> UTCTime -> [Item] -> RSS createRSS l t = RSS (rssTitle l) (rssLink l) (rssDesc l) (createChannel l t) @@ -26,7 +26,7 @@ createItem :: Entry -> Item createItem Entry{..} = [ Title $ T.unpack title , Link $ makeLink lang entryId , Description $ T.unpack btext - , PubDate edate] + , PubDate $ UTCTime edate $ secondsToDiffTime 0 ] makeLink :: BlogLang -> EntryId -> URI makeLink l i = let url = "http://tazj.in/" ++ show l ++ "/" ++ show i |