Revert "merge with 2.0"

This reverts commit 1a2ede3001feca08d1ffd37387b4e4deba43a79a.
code refactor