Hi, I find MailhandlerCommandsDefault.class.php get the Commands with regular expression.
that is good, but unfortunately the my mbox message has Date keys, it overwrite the header keys. my mail body field is :
Date:21/09/2006 URL:
http://www.thehindu.com/2006/09/21/stories/2006092102911000.htm
--------------------------------------------------------------------------------
Opinion - Leader Page Articles
and the commands get Date "21/09/2006", but it was not recognized by Feeds module, Feeds mapper Date field needs Date Time zone, format is like the mail header Date value "Thu, 21 Sep 2006 19:52:33 +0530"
So I suggest the body commands shouldn't overwrite the header keys.
I will attach the Patch the next message.
Comment | File | Size | Author |
---|---|---|---|
#1 | 1812378-fix_body_field_command.patch | 658 bytes | lixiphp |
Comments
Comment #1
lixiphp CreditAttribution: lixiphp commentedthe Patch to do is adding the message keys when the key don't exist.
Comment #2
Dane Powell CreditAttribution: Dane Powell commentedComment #3
kscheirerThat seems reasonable, is there ever a case where you would want a command to overwrite a header?
Comment #4
Dane Powell CreditAttribution: Dane Powell commentedhttp://drupalcode.org/project/mailhandler.git/commit/8b6fc3e
http://drupalcode.org/project/mailhandler.git/commit/75cf60a
Seems reasonable. It's hard to guess what kind of workflows people might use- they could certainly want to overwrite message headers. But I imagine it's pretty rare. And the alternative is sort of non-intuitive / hard to define (the result depends on whether the Header command processor runs before or after the Default command processor, for instance).
By the way, it's hard to understand from the OP, but it sounds like your problem might also be solved by #2116975: Only strip allowed commands