Properly initialize "groups"-property

`groups`-property initialized in `getGroups()` before, but if I create an instance and then call(for example) `addGroup()` it fails. Instead initialize in constructor.