Store groups in user table, minor fixes