~nikwen/account-polld/imap-new-dev

« back to all changes in this revision

Viewing changes to plugins/imap/imap.go

  • Committer: Niklas Wenzel
  • Date: 2016-03-07 20:28:42 UTC
  • Revision ID: nikwen.developer@gmail.com-20160307202842-ydvatxiopph2iuxd
test

Show diffs side-by-side

added added

removed removed

Lines of Context:
185
185
                        searchCommand = "1:* UNSEEN"
186
186
                } else if uidNextChanged {
187
187
                        log.Print("Old UIDNEXT: ", p.inboxStatus.UidNext)
188
 
                        searchCommand = strconv.Itoa(int(p.inboxStatus.UidNext)) + ":* UNSEEN" // TODO: This does not work when two messages have arrived since the last poll
 
188
                        searchCommand = strconv.Itoa(int(p.inboxStatus.UidNext)) + ":*" //" UNSEEN" // TODO: This does not work when two messages have arrived since the last poll
189
189
                        log.Print("Search command: ", searchCommand)
190
190
                }
191
191
        }
218
218
                unseenUids := cmd.Data[0].SearchResults()
219
219
 
220
220
                log.Print(fmt.Sprintf("cmd.Data length: %v", len(cmd.Data)))
 
221
                log.Print(fmt.Sprintf("Unseen length: %v", len(unseenUids)))
221
222
                log.Print(fmt.Sprintf("Unseen: %v", unseenUids))
222
223
 
223
224
                // Sort the uids (ascending)