Revert "Lots of bug fixes and improvements"

This reverts commit 676efc30cab7741580537dc896b852d7132fcc96.
Fix the messages dismatch