Remove unused files
Refactor code