Skip to content

Commit 75f1a95

Browse files
committedMar 7, 2016
merged master
2 parents a94dec2 + 680450c commit 75f1a95

File tree

3 files changed

+4
-3
lines changed

3 files changed

+4
-3
lines changed
 

‎CHANGES.txt

+1
Original file line numberDiff line numberDiff line change
@@ -17,6 +17,7 @@ Bugfixes
1717
can be re-enabled with ``-v`` option (Issue #2268)
1818
* Fix a format string in ``nikola check`` (Issue #2267)
1919
* Don't crash wordpress importer when posts are "empty" (Issue #2263)
20+
* Don't put untranslated and nonexistant posts in sitemap (Issue #2289)
2021

2122
New in v7.7.6
2223
=============

‎nikola/plugins/task/sitemap/__init__.py

+2-2
Original file line numberDiff line numberDiff line change
@@ -158,7 +158,7 @@ def scan_locs():
158158
continue
159159
alternates = []
160160
if post:
161-
for lang in kw['translations']:
161+
for lang in post.translated_to:
162162
alt_url = post.permalink(lang=lang, absolute=True)
163163
if encodelink(loc) == alt_url:
164164
continue
@@ -215,7 +215,7 @@ def scan_locs():
215215
loc = urljoin(base_url, base_path + path)
216216
alternates = []
217217
if post:
218-
for lang in kw['translations']:
218+
for lang in post.translated_to:
219219
alt_url = post.permalink(lang=lang, absolute=True)
220220
if encodelink(loc) == alt_url:
221221
continue

‎requirements-tests.txt

+1-1
Original file line numberDiff line numberDiff line change
@@ -4,5 +4,5 @@ coverage==4.0.3
44
pytest==2.9.0
55
pytest-cov==2.2.1
66
freezegun==0.3.6
7-
python-coveralls==2.6.0
7+
python-coveralls==2.7.0
88
colorama>=0.3.4

0 commit comments

Comments
 (0)
Please sign in to comment.