From 13b6fa21572fd989c06be0f0b85e70971a983f38 Mon Sep 17 00:00:00 2001 From: Lu Fei <52o@qq52o.cn> Date: Wed, 22 Nov 2023 01:14:20 -0600 Subject: [PATCH] fix(sitemap): move asf header after xmlheader (#633) This fixes #631. --- script/check-asf-header.sh | 2 +- ui/template/page.html | 1 - ui/template/question-detail.html | 1 - ui/template/sitemap-list.xml | 4 ++-- ui/template/sitemap.xml | 4 ++-- 5 files changed, 5 insertions(+), 7 deletions(-) diff --git a/script/check-asf-header.sh b/script/check-asf-header.sh index dab3b63af..ff765eab5 100755 --- a/script/check-asf-header.sh +++ b/script/check-asf-header.sh @@ -17,4 +17,4 @@ # under the License. docker run -it --rm -v $(pwd):/github/workspace ghcr.io/korandoru/hawkeye-native format -gofmt -w -l . \ No newline at end of file +gofmt -w -l . diff --git a/ui/template/page.html b/ui/template/page.html index 0cf35352c..0b18e2199 100644 --- a/ui/template/page.html +++ b/ui/template/page.html @@ -47,4 +47,3 @@ {{ end }} {{end}} -ㅤ diff --git a/ui/template/question-detail.html b/ui/template/question-detail.html index 1a388dbc2..fc276fba7 100644 --- a/ui/template/question-detail.html +++ b/ui/template/question-detail.html @@ -208,4 +208,3 @@
{{.detail.AnswerCount}} Answers
{{template "footer" .}} - diff --git a/ui/template/sitemap-list.xml b/ui/template/sitemap-list.xml index 3ad0ac99e..043812dc0 100644 --- a/ui/template/sitemap-list.xml +++ b/ui/template/sitemap-list.xml @@ -1,3 +1,4 @@ +{{ .xmlHeader }} -{{ .xmlHeader }} {{ range .page }} {{$.general.SiteUrl}}/sitemap/question-{{.}}.xml - {{ end }} + {{ end }} diff --git a/ui/template/sitemap.xml b/ui/template/sitemap.xml index 638ba3b56..2f289cd84 100644 --- a/ui/template/sitemap.xml +++ b/ui/template/sitemap.xml @@ -1,3 +1,4 @@ +{{ .xmlHeader }} -{{ .xmlHeader }} {{ range .list }} @@ -29,5 +29,5 @@ {{end}} {{.UpdateTime}} - {{ end }} + {{ end }}