lib/cache/implementer/InMemory.js
function(lifetimeInSec) {
    lifetimeInSec = Number(lifetimeInSec);
    if (isNaN(lifetimeInSec)) {
      lifetimeInSec = 0;
    }

    let lifetime = lifetimeInSec * 1000;
    if (lifetime <= 0) {
      this.expires = Date.now();
    } else {
      this.expires = Date.now() + lifetime;
    }
  }
function(lifetimeInSec) {
    lifetimeInSec = Number(lifetimeInSec);
    if (isNaN(lifetimeInSec)) {
      lifetimeInSec = 0;
    }

    let lifetime = lifetimeInSec * 1000;
    if (lifetime <= 0) {
      this.expires = Date.now();
    } else {
      this.expires = Date.now() + lifetime;
    }
  }
function ( lifetimeInSec ) { lifetimeInSec = Number ( lifetimeInSec ) ; if ( isNaN ( lifetimeInSec ) ) { lifetimeInSec = 0 ; } let lifetime = lifetimeInSec * 1000 ; if ( lifetime <= 0 ) { this . expires = Date . now ( ) ; } else { this . expires = Date . now ( ) + lifetime ; } }
Sets the expiry timestamp of the record.
@param {number} lifetimeInSec life-time is seconds after which record is considered expired.
Sets the expiry timestamp of the record .