Backport of Messenger Plugin changes from vThree. Weakreferences now don't get dropped too quickly.