Some refactor, better project structure