Fixes problem with purging groups in #279