added onRemove callback for when files get deleted