Changes some behavior introduced in #3266 .
Issue was reported at https://t.me/pythontelegrambotgroup/639987.
This change allows ExtBot.callback_data_cache to be None even if store_arbitrary_callback_data is True. Reasoning:
- We want to keep the default of
store_arbitrary_callback_datasuch that integrating persistence is as easy as possible - using arbitrary callback_data must stay opt-in
So instead of reasing an error, this PR changes the behavior such that Application.update_persistence just doesn't call update_callback_data if bot.cdc is None.
Checklist for PRs
[ ] Added.. versionadded:: version,.. versionchanged:: versionor.. deprecated:: versionto the docstrings for user facing changes (for methods/class descriptions, arguments and attributes)- Created new or adapted existing unit tests
- Documented code changes according to the CSI standard
[ ] Added myself alphabetically toAUTHORS.rst(optional)[ ] Added new classes & modules to the docs and all suitable__all__s