Kumar Akarsh
Kumar Akarsh

Reputation: 4980

Do not mark emails as read/seen using imap

In my rails application I have a rake task that reads emails using imap. The emails are read and are marked as read/seen. I do not want to mark the emails as read/seen. How can I do this?

Upvotes: 0

Views: 1032

Answers (1)

Michael Papile
Michael Papile

Reputation: 6856

http://www.rubydoc.info/stdlib/net/1.9.2/Net/IMAP/FetchData

When you fetch the email, you get the flags. You want to remove the \Seen flag.

Upvotes: 1

Related Questions