Code (Need refactor and clean)