bugfix in archiveEvents