CONN-1444: Modified the code to capture inbound Direct message Error in event logs

Modified the code to capture inbound Direct message Error in event logs.

shouldn't this be an if/else statement with the if(isMdn) statement below?