Use API Methods for Group Removal

User API methods for group removal in `User::_getUserGroups()`

- Change from SQL query to `User::exitGroup()`
- Change from SQL query to `UserInfo::deactivate()`
- Refactor to switch statement for readability

This also has the added benefit of causing events `on_user_deactivate`
and `on_user_exit_group`. The latter is very helpful when dealing with
group memberships.