Ruby Imap foo


How to tell if a message has been read or not with ruby net/imap

flags=imap.uid_fetch(uid,'FLAGS')[0].attr["FLAGS"]
seen=true if flags.include? :Seen || false

Spent a while looking for that one, and well, I learned the hard way : Stop googling and read the code


Leave a Reply