From d2e5f8406b6101971c196f40e39322e36d6bdb33 Mon Sep 17 00:00:00 2001 From: Ruben Pollan Date: Fri, 8 Dec 2017 18:10:13 +0100 Subject: [feat] Add msg_status call to the mail API To get the status of a single message providing it's mailbox and message-id. For now it only returns encryption/signature status. - Resolves: #6914 --- ui/app/lib/bitmask.js | 13 +++++++++++++ 1 file changed, 13 insertions(+) (limited to 'ui') diff --git a/ui/app/lib/bitmask.js b/ui/app/lib/bitmask.js index 6ab87ff3..45df6927 100644 --- a/ui/app/lib/bitmask.js +++ b/ui/app/lib/bitmask.js @@ -394,6 +394,19 @@ var bitmask = function(){ return call(['mail', 'get_token', uid]); }, + /** + * Get message status of one email + * + * @param {string} uid The uid to get status about + * @param {string} mbox The name of the mailbox where the message is stored + * @param {string} message_id The Message-Id from the headers of the email + * + * @return {Promise<{'secured': bool}>} Returns the status of the email + */ + msg_status: function(uid, mbox, message_id) { + return call(['mail', 'msg_status', mbox, message_id]); + }, + /** * Get status on the mixnet for an address. * -- cgit v1.2.3