diff --git a/ckan/lib/changes.py b/ckan/lib/changes.py index c3480ff4f3c..8bcab3944b9 100644 --- a/ckan/lib/changes.py +++ b/ckan/lib/changes.py @@ -225,7 +225,7 @@ def _check_metadata_changes(change_list, original, new, new_pkg): change_list.append({u'type': u'private', u'pkg_id': new_pkg['pkg_id'], u'title': new_pkg['title'], u'new': - u'Private' if bool(new['private']) \ + u'Private' if bool(new['private']) else u'Public'}) # if the description of the dataset changed @@ -305,13 +305,13 @@ def _maintainer_change(change_list, original, new, new_pkg): elif not new['maintainer']: change_list.append({u'type': u'maintainer', u'pkg_id': new_pkg['pkg_id'], u'title': new_pkg['title'], - u'method':u 'remove'}) + u'method': u'remove'}) # if there wasn't one there before else: change_list.append({u'type': 'maintainer', u'pkg_id': new_pkg['pkg_id'], u'title': new_pkg['title'], u'new_maintainer': new['maintainer'], - u'method': 'add'}) + u'method': u'add'}) def _maintainer_email_change(change_list, original, new, new_pkg): @@ -382,8 +382,8 @@ def _author_email_change(change_list, original, new, new_pkg): else: change_list.append({u'type': u'author_email', u'pkg_id': new_pkg['pkg_id'], u'title': new_pkg['title'], - u'new_author_email': new['author_email'], - u'method': u'add'}) + u'new_author_email': new['author_email'], + u'method': u'add'}) def _description_change(change_list, original, new, new_pkg): diff --git a/ckan/lib/helpers.py b/ckan/lib/helpers.py index 26068333546..5c98ec9c7ac 100644 --- a/ckan/lib/helpers.py +++ b/ckan/lib/helpers.py @@ -2710,7 +2710,7 @@ def compare_pkg_dicts(original, new, old_activity_id): change_list = [] new_pkg = {u'pkg_id': new['id'], u'name': new['name'], - u'title': new['title']} + u'title': new['title']} _check_metadata_changes(change_list, original, new, new_pkg)