Added basic purge functionality