Checks if avatar was found in cache before trying to add it to cache.
Fixes #19946
(cherry picked from commit 3a8cd7b76c)
Checks if avatar was found in cache before trying to add it to cache.
Fixes #19946
(cherry picked from commit 3a8cd7b76c)