added message validation

added validation