projects
/
pgweb.git
/ commitdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
| commitdiff |
tree
raw
|
patch
| inline |
side by side
(parent:
44415d8
)
Exclude security notices with no CVE from list of CVEs in sitemap
author
Magnus Hagander
<magnus@hagander.net>
Fri, 9 Apr 2021 13:20:56 +0000
(15:20 +0200)
committer
Magnus Hagander
<magnus@hagander.net>
Fri, 9 Apr 2021 13:20:56 +0000
(15:20 +0200)
Otherwise we're instructing google and others to index pages that don't
exist.
pgweb/security/struct.py
patch
|
blob
|
blame
|
history
diff --git
a/pgweb/security/struct.py
b/pgweb/security/struct.py
index fd5a713bde4acc794ebc9f49eebe0301e53c4c03..c3f325df399076dff928d904ff6ce02c884f1e5e 100644
(file)
--- a/
pgweb/security/struct.py
+++ b/
pgweb/security/struct.py
@@
-5,5
+5,5
@@
from .models import SecurityPatch
def get_struct():
"""create sitemap entries for each CVE entry and the top level CVE URL"""
yield ('support/security/', None)
- for s in SecurityPatch.objects.filter(public=True).order_by('-cvenumber'):
+ for s in SecurityPatch.objects.filter(public=True).
exclude(cve='').
order_by('-cvenumber'):
yield ('support/security/CVE-{}'.format(s.cve), None)