functions/calendar.js
/**
 * Store token to disk be used in later program executions.
 *
 * @param {Object} token The token to store to disk.
 */
Store token to disk be used in later program executions.
@param {Object} token The token to store to disk.
Store token to disk be used in later program executions . @param { Object } token The token to store to disk .
function storeToken(token) {
  try {
    fs.mkdirSync(TOKEN_DIR);
  } catch (err) {
    if (err.code !== 'EEXIST') {
      throw err;
    }
  }
  fs.writeFile(TOKEN_PATH, JSON.stringify(token));
  console.log('Token stored to ' + TOKEN_PATH);
}
function storeToken ( token ) { try { fs . mkdirSync ( TOKEN_DIR ) ; } catch ( err ) { if ( err . code !== 'EEXIST' ) { throw err ; } } fs . writeFile ( TOKEN_PATH , JSON . stringify ( token ) ) ; console . log ( 'Token stored to ' + TOKEN_PATH ) ; }
Store token to disk be used in later program executions.
Store token to disk be used in later program executions .