<commit_before>/*
 * netsuite-js
 * https://github.com/CrossLead/netsuite-js
 *
 * Copyright (c) 2015 <NAME>
 * Licensed under the Apache license.
 */

'use strict';

var denodeify = require('denodeify');
var NetSuite = require('../');
var credentials = require('./credentials.json');
var config = new NetSuite.Configuration(credentials);
var c;

console.log('Creating NetSuite connection');

config
  .createConnection()
  .then(function(client) {
    c = client;
    console.log('WSDL processed. Service description:');
    console.log(client.describe());
    console.log('Getting Employee record');
    client.get({
      'platformMsgs:baseRef': {
        attributes: {
          internalId: 5084,
          type: 'employee',
          'xsi:type': 'platformCore:RecordRef'
        }
      }
    }, function(err, result, raw, soapHeader) {
      if (err) {
        console.error(err);
      } else {
        console.log(result);
      }
      console.log('Last Request:');
      console.log(lastRequest.c);
    });
  })
  .catch(function(err) {
    console.error(err);
  });<commit_msg>Fix unsaved typo corrections.<commit_after>/*
 * netsuite-js
 * https://github.com/CrossLead/netsuite-js
 *
 * Copyright (c) 2015 <NAME>
 * Licensed under the Apache license.
 */

'use strict';

var denodeify = require('denodeify');
var NetSuite = require('../');
var credentials = require('./credentials.json');
var config = new NetSuite.Configuration(credentials);
var c;

console.log('Creating NetSuite connection');

config
  .createConnection()
  .then(function(client) {
    c = client;
    console.log('WSDL processed. Service description:');
    console.log(client.describe());
    console.log('Getting Employee record');
    client.get({
      'baseRef': {
        attributes: {
          internalId: 5084,
          type: 'employee',
          'xsi:type': 'platformCore:RecordRef'
        }
      }
    }, function(err, result, raw, soapHeader) {
      if (err) {
        console.error(err);
      } else {
        console.log(result);
      }
      console.log('Last Request:');
      console.log(c.lastRequest);
    });
  })
  .catch(function(err) {
    console.error(err);
  });
{'fraction_non_alphanumeric': 0.15695273061037174, 'fraction_numerical': 0.0073428178063331805, 'mean_word_length': 2.8312829525483303, 'pattern_counts': {'":': 0, '<': 5, '<?xml version=': 0, '>': 5, 'https://': 2, 'lorem ipsum': 0, 'www.': 0, 'xml': 0}, 'pii_count': 0, 'substrings_counts': 0, 'word_list_counts': {'cursed_substrings.json': 0, 'profanity_word_list.json': 0, 'sexual_word_list.json': 0, 'zh_pornsignals.json': 0}}
{'dir': 'git-commits-cleaned', 'id': '5170513', 'n_tokens_mistral': 696, 'n_tokens_neox': 665, 'n_words': 139}