From d7b3a0e78ac168db711c3e300b4b4c05021dfaf7 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Tim-Niclas=20Oelschl=C3=A4ger?= Date: Sat, 10 Feb 2024 00:06:20 +0100 Subject: [PATCH 1/2] enhancement: Show 'view-path' link always in commits_list --- templates/repo/commits_list.tmpl | 2 ++ 1 file changed, 2 insertions(+) diff --git a/templates/repo/commits_list.tmpl b/templates/repo/commits_list.tmpl index 7702770c406f..e31fa57af160 100644 --- a/templates/repo/commits_list.tmpl +++ b/templates/repo/commits_list.tmpl @@ -80,6 +80,8 @@ {{if $.FileName}} {{svg "octicon-file-code"}} + {{else}} + {{svg "octicon-file-code"}} {{end}} From 91ee56bf8b18628ecae0f69f39a87fe53235f960 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Tim-Niclas=20Oelschl=C3=A4ger?= Date: Sat, 10 Feb 2024 01:00:03 +0100 Subject: [PATCH 2/2] review: inline if-else --- templates/repo/commits_list.tmpl | 11 ++++++----- 1 file changed, 6 insertions(+), 5 deletions(-) diff --git a/templates/repo/commits_list.tmpl b/templates/repo/commits_list.tmpl index e31fa57af160..4eb31e0e8e69 100644 --- a/templates/repo/commits_list.tmpl +++ b/templates/repo/commits_list.tmpl @@ -78,11 +78,12 @@ {{end}} - {{if $.FileName}} - {{svg "octicon-file-code"}} - {{else}} - {{svg "octicon-file-code"}} - {{end}} + + {{svg "octicon-file-code"}} + {{end}}