In the next diff, we'll remove the MessageData parameter from getMessageNotifyType. We want to do this because for DMs, we need to call this function on the recipient's side in order to determine whether to set a thread to unread. But the recipient does not have access to the MessageData.
The only place where we need the MessageData in getMessageNotifyType is multimediaMessageSpec. This usage was introduced in D6798 to prevent double-notifs on sidebar creation in both textMessageSpec and multimediaMessageSpec. However, in D6938 we introduced an alternative approach to prevent double-notifs in textMessageSpec; this diff uses the same approach for multimediaMessageSpec.
Depends on D14339