Skip to content

Suggestion for getDecodedValue(): Don't remove comments #261

Description

@ThomasLandauer

Message:

Auto-Submitted: =?UTF-8?Q?auto-replied (vacation)?=
  • ->getHeader()->getRawValue() gives:
=?UTF-8?Q?auto-replied (vacation)?=
  • ->getHeaderValue() gives:
auto-replied (vacation)
  • ->getDecodedValue() gives:
auto-replied (vacation)

So the winners are getHeaderValue() or getDecodedValue()


But when the header doesn't contain the (unnecessary) encoding:

Auto-Submitted: auto-replied (vacation)
  • ->getHeader()->getRawValue() gives:
auto-replied (vacation)
  • ->getHeaderValue() gives:
auto-replied
  • ->getDecodedValue() gives:
auto-replied

So the winner is getRawValue()

Bottom line: Neither method fits in both situations. So what's the easiest way to get such a method (apart from inventing a new one)?
I think getDecodedValue could be changed to keep the part in parentheses ("comment").

Activity

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Projects

    No projects

      Milestone

      No milestone

      Relationships

      None yet

      Development

      No branches or pull requests

      Issue actions