Improve new char logic and debug