FIX: Don't grant sharing badges to users who don't exist (PR #13851)

Check that the user exists in badge queries for ‘First Share’ and ‘Nice/Good/Great Share’ badges,

For ‘Nice+ Share’ badges, also grant badges if the number of shares is equal to the threshold count to better match the descriptions.


This pull request has been mentioned on Discourse Meta. There might be relevant details there:

nice tidy and clear PR, thanks @wbhouston