replace message implemented