Code Refactor

Uncompleted