Skip to content

Headers() needs to use textproto.Mimeheader.Set() instead of modifying the map directly #43

Open
@ericychoi

Description

@ericychoi

https://github.com/sendgrid/go-gmime/blame/5544c54b141c13fa6ac0b4ddc162a65dab1dc8bb/gmime/envelope.go#L64

When Canonical form of the key is different from the actual key, headers().Values() would not return the right value, since the internal map doesn't have the canonical form as the key. Users can get the values by treating Mimeheader as a map as a workaround- but this is confusing and can cause unexpected consequences.

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions