diff options
author | Jefferson Stachelski <jstachel@thoughtworks.com> | 2016-02-23 15:32:43 -0300 |
---|---|---|
committer | Jefferson Stachelski <jstachel@thoughtworks.com> | 2016-02-23 15:32:43 -0300 |
commit | b2184de2a81beea26cf3e68d769612df4ba156f3 (patch) | |
tree | 378ef748926b5c309a1d5fda7b16c59c7c9f404d /web-ui | |
parent | b9d24494586db59d4bf316a2fac875967b21c17a (diff) |
Returning 'not-sign' for no signature information
When leap.mail receive not encrypted and not signed email it show as
no-signature-information on pixelated
Paring @thaissiqueira / @jeffhsta
Issue #605
Diffstat (limited to 'web-ui')
-rw-r--r-- | web-ui/app/js/mail_view/ui/mail_view.js | 4 | ||||
-rw-r--r-- | web-ui/test/spec/mail_view/ui/mail_view.spec.js | 2 |
2 files changed, 3 insertions, 3 deletions
diff --git a/web-ui/app/js/mail_view/ui/mail_view.js b/web-ui/app/js/mail_view/ui/mail_view.js index ba4d6e85..d4f5dd9e 100644 --- a/web-ui/app/js/mail_view/ui/mail_view.js +++ b/web-ui/app/js/mail_view/ui/mail_view.js @@ -51,7 +51,7 @@ define( data.mail.security_casing = data.mail.security_casing || {}; signed = this.checkSigned(data.mail); encrypted = this.checkEncrypted(data.mail); - attachments = data.mail.attachments.map(function (attachment) { + attachments = data.mail.attachments.map(function (attachment) { attachment.received = true; return attachment; }); @@ -125,7 +125,7 @@ define( }); if(hasNoSignatureInformation) { - return ''; + return 'not-signed'; } var status = ['signed']; diff --git a/web-ui/test/spec/mail_view/ui/mail_view.spec.js b/web-ui/test/spec/mail_view/ui/mail_view.spec.js index 1c1446f9..ae874621 100644 --- a/web-ui/test/spec/mail_view/ui/mail_view.spec.js +++ b/web-ui/test/spec/mail_view/ui/mail_view.spec.js @@ -165,7 +165,7 @@ describeComponent('mail_view/ui/mail_view', function () { it('assumes that there is no signature info to show', function() { var email = testData; email.security_casing = {imprints: [{state: 'no_signature_information'}]}; - expect(this.component.checkSigned(email)).toEqual(''); + expect(this.component.checkSigned(email)).toEqual('not-signed'); }); it('shows that mail is encrypted if it is', function() { |