reverted changes and added file cleanup