From aed402c5d572b60246f1f8e57ae269f8c91b0b7c Mon Sep 17 00:00:00 2001 From: Maximilian Krambach Date: Wed, 13 Jun 2018 15:22:03 +0200 Subject: js: getDefaultKey and verify fix -- * DemoExtension/maindemo.js - added a Demo for retrieving the default signing key * src/Errors.js - add a new Error if no default key can be determined * src/Key.js added documentation and a TODO marker for hasSecret. * src/Keyring.js implemented getDefaultKey * src/permittedOperations.js: Added missing entry for verify, added config_opt --- lang/js/src/Key.js | 8 ++++++++ 1 file changed, 8 insertions(+) (limited to 'lang/js/src/Key.js') diff --git a/lang/js/src/Key.js b/lang/js/src/Key.js index 5986254e..3e4f1c78 100644 --- a/lang/js/src/Key.js +++ b/lang/js/src/Key.js @@ -192,6 +192,7 @@ export class GPGME_Key { * Query the armored block of the non- secret parts of the Key directly * from gpg. * @returns {Promise} + * @async */ getArmor(){ let me = this; @@ -211,6 +212,13 @@ export class GPGME_Key { }); } + /** + * Find out if the Key includes a secret part + * @returns {Promise} + * + * @async + */ + // TODO: Does not work yet, result is always false getHasSecret(){ let me = this; return new Promise(function(resolve, reject) { -- cgit v1.2.3