Code refactor + cleanup + names