dvMailWireHeaders function

Map<String, String> dvMailWireHeaders(
  1. DVMailMessage message
)

Every header message should reach the wire with.

An explicit entry in message.headers wins over the one priority would have added. Someone writing the header by hand has said something more specific than the enum can, and silently overwriting it would leave the typed field and the escape hatch fighting over the same wire bytes.

Implementation

Map<String, String> dvMailWireHeaders(DVMailMessage message) =>
    <String, String>{
      ...dvMailPriorityHeaders(message.priority),
      ...message.headers,
    };