Skip to content

Commit 7e26c50

Browse files
authored
[ANG-1044] Fix sitemap for preprint files download (#11357)
1 parent 76d55f4 commit 7e26c50

File tree

2 files changed

+4
-4
lines changed

2 files changed

+4
-4
lines changed

osf_tests/test_generate_sitemap.py

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -141,9 +141,9 @@ def all_included_links(self, user_admin_project_public, user_admin_project_priva
141141
f'/preprints/{provider_osf._id}/{preprint_osf_version._id}',
142142
f'/preprints/{provider_other._id}/{preprint_other._id}',
143143
f'/preprints/{provider_osf._id}/{preprint_withdrawn._id}',
144-
f'/{preprint_osf._id}/download/?format=pdf',
145-
f'/{preprint_osf_version._id}/download/?format=pdf',
146-
f'/{preprint_other._id}/download/?format=pdf'
144+
f'/download/{preprint_osf._id}/?format=pdf',
145+
f'/download/{preprint_osf_version._id}/?format=pdf',
146+
f'/download/{preprint_other._id}/?format=pdf'
147147
])
148148
urls_to_include = [urljoin(settings.DOMAIN, item) for item in urls_to_include]
149149

scripts/generate_sitemap.py

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -229,8 +229,8 @@ def generate(self):
229229
file_config['loc'] = urljoin(
230230
settings.DOMAIN,
231231
os.path.join(
232-
obj._id,
233232
'download',
233+
obj._id,
234234
'?format=pdf'
235235
)
236236
)

0 commit comments

Comments
 (0)