Issue #2952634 by Sut3kh, alexpott, Rob C, jibran: LegacyMessenger::deleteByType does not delete anything (cherry picked from commit 7353b6f1)