Got the case were somebody used this separator in the email body to split the mail into sections:
/^________________________________$/
The mail also didn't had an actual signature, it looked like:
Section 1
________________________________
Section 2
________________________________
Section 3
________________________________
Section 4
On 24/03/25 10:55, Me wrote:
...
The reply parser returns only "Section 1".
Some ideas (but really not sure how to best handle this):
- You could only cut off after the last signature separator but then you still lose "Section 4"
- If there are multiple signature separators don't remove them at all (but then you still miss the case where there is only one signature separator)
- Require a max number of lines/chars to recognize a signature, e.g. if "Section 4" is too long don't tread it as a signature.
Got the case were somebody used this separator in the email body to split the mail into sections:
/^________________________________$/The mail also didn't had an actual signature, it looked like:
The reply parser returns only "Section 1".
Some ideas (but really not sure how to best handle this):