Use an Esqueleto query to efficiently fetch and render the user profiles on h-cards, rather than several queries and lots of fussing around

This commit is contained in:
Danielle McLean 2017-10-11 13:16:47 +11:00
parent f3b12ded69
commit 0055a4160b
Signed by: 00dani
GPG key ID: 5A5D2D1AFF12EEC5
3 changed files with 15 additions and 37 deletions

View file

@ -18,9 +18,9 @@
<a .u-email itemprop="email" rel="me" href="mailto:#{userEmail user}">
<i .fa.fa-envelope>
#{userEmail user}
$forall ((site, template), profile) <- userProfiles
$forall (Entity _ site, Entity _ profile) <- userProfiles
<li>
<a .u-url itemprop="sameAs" rel="me" href="#{substitute template profile}">
<a .u-url itemprop="sameAs" rel="me" href="#{profileUrl site profile}">
<i .#{siteIcon site}>
$maybe name <- profileDisplayName profile
#{name}