mirror of https://github.com/zulip/zulip.git
1562ec758e
Currently, we use -1 as the Realm.message_retention_days value to retain message forever unless specified at stream level for a particular stream, that is, no policy set at the realm level. But this is incoherent with what we use for Stream.message_retention_days where -1 means > disable retention policy for this stream unconditionally that can be confusing from an API standpoint. So instead of trying some hack to reset the value to NULL or using some other value like -2 for RETAIN_MESSAGE_FOREVER and use that for API. It is much more intuitive to use a string like 'forever' that can be mapped to RETAIN_MESSAGE_FOREVER at the backend. And this is similar to what we use for streams settings as well. |
||
---|---|---|
.. | ||
data_import | ||
lib | ||
management | ||
migrations | ||
openapi | ||
templatetags | ||
tests | ||
tornado | ||
views | ||
webhooks | ||
worker | ||
__init__.py | ||
apps.py | ||
context_processors.py | ||
decorator.py | ||
filters.py | ||
forms.py | ||
logging_handlers.py | ||
middleware.py | ||
models.py | ||
signals.py |