diff options
author | Maximilian Krambach <[email protected]> | 2018-06-20 11:42:19 +0000 |
---|---|---|
committer | Maximilian Krambach <[email protected]> | 2018-06-20 11:46:41 +0000 |
commit | 88e7f8ec2ef3d90ca014b0bdb246f4d99f82abc8 (patch) | |
tree | 3cec557863b6669d9ea94c4f43bd5a3e861cc3f1 /lang/js/src/gpgmejs.js | |
parent | Prepare build system for gpgme-js and dist it (diff) | |
download | gpgme-88e7f8ec2ef3d90ca014b0bdb246f4d99f82abc8.tar.gz gpgme-88e7f8ec2ef3d90ca014b0bdb246f4d99f82abc8.zip |
js: Demoextension update
--
* src/Signature: typo
* src/gpgmejs.js: fixed wrong scope in verification
* right now verify does not succeed in the DemoExtension.
This is probably a problem in conversion or line ending.
Diffstat (limited to '')
-rw-r--r-- | lang/js/src/gpgmejs.js | 6 |
1 files changed, 3 insertions, 3 deletions
diff --git a/lang/js/src/gpgmejs.js b/lang/js/src/gpgmejs.js index a0f7e968..c2a6b8b6 100644 --- a/lang/js/src/gpgmejs.js +++ b/lang/js/src/gpgmejs.js @@ -168,7 +168,7 @@ export class GpgME { /** * Sign a Message - * @param {String|Object} data text/data to be decrypted. Accepts Strings + * @param {String|Object} data text/data to be signed. Accepts Strings * and Objects with a gettext methos * @param {GPGME_Key|String|Array<String>|Array<GPGME_Key>} keys The * key/keys to use for signing @@ -238,7 +238,7 @@ export class GpgME { */ verify(data, signature, base64 = false){ let msg = createMessage('verify'); - let dt = this.putData(msg, data); + let dt = putData(msg, data); if (dt instanceof Error){ return Promise.reject(dt); } @@ -317,7 +317,7 @@ function collectSignatures(sigs){ for (let i=0; i< sigs.length; i++){ let sigObj = createSignature(sigs[i]); if (sigObj instanceof Error){ - return gpgme_error('SIG_WRONG'); + return gpgme_error(sigObj); } if (sigObj.valid !== true){ summary.failures += 1; |