typo corrections and strip() added to msg parsing