Fixed behaviour of history when groups no longer exist