fixing gid handling if group doesn't exist yet