Put the <link>s for PGP keys into the page header instead of the h-card itself, since it's invalid HTML to have <link> in the body
This commit is contained in:
parent
9d0d6ba249
commit
44288b419c
2 changed files with 6 additions and 2 deletions
|
@ -1,5 +1,6 @@
|
|||
{-# LANGUAGE NoImplicitPrelude #-}
|
||||
{-# LANGUAGE OverloadedStrings #-}
|
||||
{-# LANGUAGE QuasiQuotes #-}
|
||||
{-# LANGUAGE TemplateHaskell #-}
|
||||
module Widget.Card ( hCard ) where
|
||||
|
||||
|
@ -31,4 +32,8 @@ hCard (Entity userId user) = do
|
|||
E.orderBy [E.asc $ site ^. SiteName]
|
||||
return (site, profile)
|
||||
pgpKeys <- handlerToWidget . runDB $ map entityVal <$> selectList [PgpKeyUserId ==. userId] []
|
||||
toWidgetHead [hamlet|
|
||||
$forall key <- pgpKeys
|
||||
<link rel="pgpkey" type="application/pgp-keys" href=@{routeFromPgp key}>
|
||||
|]
|
||||
$(widgetFile "mf2/h-card")
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue