When we are reading from or putting to the cache, there is no need to deep copy objects now because the cache is already serialized. We also delete some lines from tests because the mock store directly returns the pointers whereas actually they would be returned from the database where a serialization occurs again. So we would be testing for the wrong thing by unnecessarily keeping the deep copies for DB reads. https://mattermost.atlassian.net/browse/MM-27883 Co-authored-by: Mattermod <mattermod@users.noreply.github.com>