imap: simplify format of conversation threads

Now, the JSON returned looks like: [{'Date': 394839,
'Thread':[{...}...]}, ...]. The frontend is yet to cope with this
change.
www/mailbox: first cut of coping with new json