Title: fetchMessageSource on pImapMailServer.php
Last modified: September 25, 2018

---

# fetchMessageSource on pImapMailServer.php

 *  Resolved [webtecky](https://wordpress.org/support/users/webtecky/)
 * (@webtecky)
 * [7 years, 8 months ago](https://wordpress.org/support/topic/fetchmessagesource-on-pimapmailserver-php/)
 * Why is there a condition that stops the fetching if there is a line with only
   an opened parenthesis on line 94 (lib/pImapMailServer.php)? We received an email
   with a paragraph ending with a closed parenthesis and it got cut out (the parenthesis
   fell in a new line with nothing after that). We had to disable the condition 
   in order to make it work.
 * Robert

Viewing 4 replies - 1 through 4 (of 4 total)

 *  Plugin Author [Wayne Allen](https://wordpress.org/support/users/wayneallen-1/)
 * (@wayneallen-1)
 * [7 years, 8 months ago](https://wordpress.org/support/topic/fetchmessagesource-on-pimapmailserver-php/#post-10727552)
 * Because that is how IMAP works. If you want to know the gory details see [https://tools.ietf.org/html/rfc2060](https://tools.ietf.org/html/rfc2060)
 * Take a look at page 63 for an example.
 *  Thread Starter [webtecky](https://wordpress.org/support/users/webtecky/)
 * (@webtecky)
 * [7 years, 8 months ago](https://wordpress.org/support/topic/fetchmessagesource-on-pimapmailserver-php/#post-10732616)
 * Thanks for the explanation, but that approach interferes with a regular parenthesis
   in the message body. I would make the loop break when it finds a “A0006 OK” (
   IMAP-SSL/gmail) or “a004 OK FETCH” string (example on page 63), so the email 
   would not be cut out. I know it’s very rare, but it happened to me (and it could
   happen to others).
 * Kudos to the plugin though!
 * Best.
 *  Plugin Author [Wayne Allen](https://wordpress.org/support/users/wayneallen-1/)
 * (@wayneallen-1)
 * [7 years, 8 months ago](https://wordpress.org/support/topic/fetchmessagesource-on-pimapmailserver-php/#post-10736170)
 * I will look into this a bit more, but as I didn’t write the IMAP parsing and 
   the library I used isn’t being updated it may take awhile.
 *  Plugin Author [Wayne Allen](https://wordpress.org/support/users/wayneallen-1/)
 * (@wayneallen-1)
 * [7 years, 5 months ago](https://wordpress.org/support/topic/fetchmessagesource-on-pimapmailserver-php/#post-11067167)
 * FYI there is an update coming soon that fixes this issue. Thanks for bringing
   it to my attention.

Viewing 4 replies - 1 through 4 (of 4 total)

The topic ‘fetchMessageSource on pImapMailServer.php’ is closed to new replies.

 * ![](https://ps.w.org/postie/assets/icon-256x256.png?rev=970083)
 * [Postie](https://wordpress.org/plugins/postie/)
 * [Frequently Asked Questions](https://wordpress.org/plugins/postie/#faq)
 * [Support Threads](https://wordpress.org/support/plugin/postie/)
 * [Active Topics](https://wordpress.org/support/plugin/postie/active/)
 * [Unresolved Topics](https://wordpress.org/support/plugin/postie/unresolved/)
 * [Reviews](https://wordpress.org/support/plugin/postie/reviews/)

 * 4 replies
 * 2 participants
 * Last reply from: [Wayne Allen](https://wordpress.org/support/users/wayneallen-1/)
 * Last activity: [7 years, 5 months ago](https://wordpress.org/support/topic/fetchmessagesource-on-pimapmailserver-php/#post-11067167)
 * Status: resolved