clean up, add stats