add cleanup code