aboutsummaryrefslogtreecommitdiffstats
path: root/lang/js/src/Keyring.js
diff options
context:
space:
mode:
authorMaximilian Krambach <[email protected]>2018-05-03 12:12:10 +0000
committerMaximilian Krambach <[email protected]>2018-05-03 12:12:10 +0000
commit6f67814eb45725bc7f3736a2638bad0a7470f17a (patch)
treea2958b05e9f6bb127a0c815dd2a12504465be550 /lang/js/src/Keyring.js
parentjs: more testing (diff)
downloadgpgme-6f67814eb45725bc7f3736a2638bad0a7470f17a.tar.gz
gpgme-6f67814eb45725bc7f3736a2638bad0a7470f17a.zip
js: changed Key class stub
-- * src/Key.js: A Key object cannot offer more than basic functionality outside a connection, so it now requires a connection to be present.
Diffstat (limited to 'lang/js/src/Keyring.js')
-rw-r--r--lang/js/src/Keyring.js3
1 files changed, 2 insertions, 1 deletions
diff --git a/lang/js/src/Keyring.js b/lang/js/src/Keyring.js
index d1f4122e..2cf87c24 100644
--- a/lang/js/src/Keyring.js
+++ b/lang/js/src/Keyring.js
@@ -61,6 +61,7 @@ export class GPGME_Keyring {
if (include_secret){
msg.setParameter('with-secret', true);
}
+ let me = this;
this.connection.post(msg).then(function(result){
let fpr_list = [];
@@ -72,7 +73,7 @@ export class GPGME_Keyring {
fpr_list = result.keys;
}
for (let i=0; i < fpr_list.length; i++){
- let newKey = new GPGME_Key(fpr_list[i]);
+ let newKey = new GPGME_Key(fpr_list[i], me._connection);
if (newKey instanceof GPGME_Key){
resultset.push(newKey);
}