summaryrefslogtreecommitdiffstats
path: root/templates/explore/users.tmpl
diff options
context:
space:
mode:
authorwxiaoguang <wxiaoguang@gmail.com>2023-08-10 11:19:39 +0800
committerGitHub <noreply@github.com>2023-08-10 11:19:39 +0800
commita370efc13f0e1ea309e324639832832bc14cb6dc (patch)
tree3c408cf225a4ffcc49f257fabf162831c92e23bf /templates/explore/users.tmpl
parent36eb3c433ae384f21beec63eb648141fb9dba676 (diff)
downloadgitea-a370efc13f0e1ea309e324639832832bc14cb6dc.tar.gz
gitea-a370efc13f0e1ea309e324639832832bc14cb6dc.zip
Use template context function for avatar rendering (#26385)
Introduce `AvatarUtils`, no need to pass `$.Context` to every sub-template, and simplify the template helper functions.
Diffstat (limited to 'templates/explore/users.tmpl')
-rw-r--r--templates/explore/users.tmpl2
1 files changed, 1 insertions, 1 deletions
diff --git a/templates/explore/users.tmpl b/templates/explore/users.tmpl
index 5e150f692f..1280f4add6 100644
--- a/templates/explore/users.tmpl
+++ b/templates/explore/users.tmpl
@@ -8,7 +8,7 @@
{{range .Users}}
<div class="flex-item flex-item-center">
<div class="flex-item-leading">
- {{avatar $.Context . 48}}
+ {{ctx.AvatarUtils.Avatar . 48}}
</div>
<div class="flex-item-main">
<div class="flex-item-title">