Refactored MsgSend function
Merge remote-tracking branch 'vyrly/master'