diff options
-rw-r--r-- | src/mod_mam.erl | 2 |
1 files changed, 2 insertions, 0 deletions
diff --git a/src/mod_mam.erl b/src/mod_mam.erl index 10eb098da..7e1460695 100644 --- a/src/mod_mam.erl +++ b/src/mod_mam.erl @@ -1032,6 +1032,8 @@ filter_by_max(_Msgs, _Junk) -> limit_max(RSM, ?NS_MAM_TMP) -> RSM; % XEP-0313 v0.2 doesn't require clients to support RSM. +limit_max(none, _NS) -> + #rsm_in{max = ?DEF_PAGE_SIZE}; limit_max(#rsm_in{max = Max} = RSM, _NS) when not is_integer(Max) -> RSM#rsm_in{max = ?DEF_PAGE_SIZE}; limit_max(#rsm_in{max = Max} = RSM, _NS) when Max > ?MAX_PAGE_SIZE -> |