Purge in memory in modules before consolidating, closes #2700