added deletion of classes.