Revert "Revert "clean code""

This reverts commit fed7fd6cde801451720b745d4e7cb0fe55835361.