Fix get_user_groups utility function.
The getgrouplist returns either 0 on success or -1 on error, while get_user_groups() itself is intended to return a group count.
Before this fix the User.SetAccountType() method was removing a user from all its groups.
Sponsored by: Serenity Cybersecurity, LLC