summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
-rw-r--r--src/mailman/docs/NEWS.rst2
-rw-r--r--src/mailman/rest/docs/preferences.rst3
-rw-r--r--src/mailman/rest/preferences.py1
3 files changed, 6 insertions, 0 deletions
diff --git a/src/mailman/docs/NEWS.rst b/src/mailman/docs/NEWS.rst
index a2b599cbc..3f85f5b40 100644
--- a/src/mailman/docs/NEWS.rst
+++ b/src/mailman/docs/NEWS.rst
@@ -25,6 +25,8 @@ REST
attributes of a mailing list's configuration. (LP: #1157881)
* Support pagination of some large collections (lists, users, members).
Given by Florian Fuchs. (LP: #1156529)
+ * Expose ``hide_address`` to the ``.../preferences`` REST API. Contributed
+ by Sneha Priscilla.
Configuration
-------------
diff --git a/src/mailman/rest/docs/preferences.rst b/src/mailman/rest/docs/preferences.rst
index e82fd6001..8694364a4 100644
--- a/src/mailman/rest/docs/preferences.rst
+++ b/src/mailman/rest/docs/preferences.rst
@@ -95,6 +95,7 @@ PUT operation.
... 'acknowledge_posts': True,
... 'delivery_mode': 'plaintext_digests',
... 'delivery_status': 'by_user',
+ ... 'hide_address': False,
... 'preferred_language': 'ja',
... 'receive_list_copy': True,
... 'receive_own_postings': False,
@@ -109,6 +110,7 @@ PUT operation.
acknowledge_posts: True
delivery_mode: plaintext_digests
delivery_status: by_user
+ hide_address: False
http_etag: "..."
preferred_language: ja
receive_list_copy: True
@@ -133,6 +135,7 @@ You can also update just a few of the attributes using PATCH.
acknowledge_posts: True
delivery_mode: plaintext_digests
delivery_status: by_user
+ hide_address: False
http_etag: "..."
preferred_language: ja
receive_list_copy: False
diff --git a/src/mailman/rest/preferences.py b/src/mailman/rest/preferences.py
index d392c0299..49db6c632 100644
--- a/src/mailman/rest/preferences.py
+++ b/src/mailman/rest/preferences.py
@@ -84,6 +84,7 @@ class Preferences(ReadOnlyPreferences):
return http.not_found()
kws = dict(
acknowledge_posts=GetterSetter(as_boolean),
+ hide_address = GetterSetter(as_boolean),
delivery_mode=GetterSetter(enum_validator(DeliveryMode)),
delivery_status=GetterSetter(enum_validator(DeliveryStatus)),
preferred_language=GetterSetter(language_validator),