#89 Composer move sign/encrypt buttons from menu to view

This commit is contained in:
the-djmaze 2022-02-04 16:21:29 +01:00
parent 26d3509e28
commit 5b051745fe
6 changed files with 152 additions and 174 deletions

View file

@ -145,12 +145,12 @@ export const OpenPGPUserStore = new class {
/**
* Checks if verifying/encrypting a message is possible with given email addresses.
*/
hasPublicKeyForEmails(recipients, all) {
hasPublicKeyForEmails(recipients) {
const count = recipients.length,
length = count ? recipients.filter(email =>
this.publicKeys().find(key => key.emails.includes(email))
).length : 0;
return length && (!all || length === count);
return length && length === count;
}
getPrivateKeyFor(query/*, sign*/) {