Refactoring and handling gravatar in case user doesn't use social networks