js: don't expire new keys if no date is set

--

* src/Keyring.js A new Key without expiration is documented as
  'never expire' here, and should behave accordingly. This requires
  sending '0' here.
This commit is contained in:
Maximilian Krambach 2018-08-17 17:20:35 +02:00
parent 3fb094a9b8
commit 8e87790db3

View File

@ -390,6 +390,8 @@ export class GPGME_Keyring {
if (expires){
msg.setParameter('expires',
Math.floor(expires.valueOf()/1000));
} else {
msg.setParameter('expires', 0);
}
msg.post().then(function(response){
me.getKeys(response.fingerprint, true).then(