Fix multiple memberships per course

If a user was a member of multiple groups in a course, there was a
Moodle error because the record ids were not unique.
Undo quick fix, test works now

userid has nothing to do with testing if a group belongs to a course.
Add default maxsize setting

The admin can now set a global default value for the maxsize field in
the settings form.
Fix validation not working

Fixed my typo... (see diff)