class_exists fix
Validate & handle messages in reverse order