5041 total user statistic shouldnt include closed accounts

I'm new to this, sorry if I've done anything wrong!
Saw this: https://github.com/diaspora/diaspora/issues/5041 and attempted to fix it, put the logic in the model rather than the presenter. 
The query searches for users with a username (to exclude invitations - mentioned in the thread) and Users with closed accounts.