Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Bump eslint-config-standard from 13.0.1 to 16.0.1 #66

Merged
merged 2 commits into from
Nov 18, 2020
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
1 change: 1 addition & 0 deletions CHANGELOG.md
Original file line number Diff line number Diff line change
Expand Up @@ -9,6 +9,7 @@
- CHANGED: Bump nock from 13.0.0 to 13.0.4
- CHANGED: Bump mocha from 8.0.1 to 8.2.1
- CHANGED: Bump snazzy from 8.0.0 to 9.0.0
- CHANGED: Bump eslint-config-standard from 13.0.1 to 16.0.1
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

@san983 FYI no need to track every single dependency update in the CHANGELOG, unless it has significant impact on the final user.


## Release 4.2.1

Expand Down
2 changes: 1 addition & 1 deletion lib/dnsimple.js
Original file line number Diff line number Diff line change
Expand Up @@ -78,7 +78,7 @@ Dnsimple.prototype = {
},

_setupServices: function () {
for (var name in services) {
for (const name in services) {
this[name] = new services[name](this.client);
}
}
Expand Down
16 changes: 8 additions & 8 deletions lib/dnsimple/client.js
Original file line number Diff line number Diff line change
Expand Up @@ -39,15 +39,15 @@ class Client {
}

request (method, path, data, options) {
var timeout = this._dnsimple.timeout;
var headers = {
const timeout = this._dnsimple.timeout;
const headers = {
Authorization: `Bearer ${this._dnsimple.accessToken()}`,
Accept: 'application/json',
'Content-Type': 'application/json',
'User-Agent': this._dnsimple.userAgent()
};

var req = https.request({
const req = https.request({
host: this._dnsimple.baseUrl().hostname,
port: this._dnsimple.baseUrl().port || 443,
path: this._versionedPath(path, options),
Expand Down Expand Up @@ -79,8 +79,8 @@ class Client {

_responseHandler (req, resolve, reject) {
return (res) => {
var data = '';
var error;
let data = '';
let error;

res.setEncoding('utf8');
res.on('data', (chunk) => { data += chunk; });
Expand Down Expand Up @@ -121,7 +121,7 @@ class Client {
_errorHandler (req, reject) {
return (error) => {
if (!req._isAborted) {
var errorObj = {
const errorObj = {
description: 'An error occurred communicating with DNSimple API',
error: error
};
Expand All @@ -131,8 +131,8 @@ class Client {
}

_versionedPath (path, options) {
var versionedPath = '/v2' + path;
var query = {};
let versionedPath = '/v2' + path;
const query = {};

if (!(typeof options.query === 'undefined')) {
for (const key in options.query) {
Expand Down
2 changes: 1 addition & 1 deletion lib/dnsimple/webhooks.js
Original file line number Diff line number Diff line change
Expand Up @@ -41,7 +41,7 @@ class Webhooks {
* @return {Promise}
*/
allWebhooks (accountId, options = {}) {
var self = this;
const self = this;
return new Promise(function (resolve, reject) {
self.listWebhooks(accountId, options).then(function (response) {
resolve(response.data);
Expand Down
6 changes: 3 additions & 3 deletions package-lock.json

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

2 changes: 1 addition & 1 deletion package.json
Original file line number Diff line number Diff line change
Expand Up @@ -29,7 +29,7 @@
"devDependencies": {
"chai": "^4.1.2",
"chai-as-promised": "^7.1.1",
"eslint-config-standard": "^13.0.1",
"eslint-config-standard": "^16.0.1",
"js-yaml": ">=3.13.1",
"lodash": ">=4.17.13",
"mocha": "^8.0.1",
Expand Down
6 changes: 3 additions & 3 deletions test/dnsimple.spec.js
Original file line number Diff line number Diff line change
@@ -1,11 +1,11 @@
'use strict';

var testUtils = require('./testUtils');
var dnsimple = require('../lib/dnsimple')(
const testUtils = require('./testUtils');
const dnsimple = require('../lib/dnsimple')(
testUtils.getAccessToken()
);

var expect = require('chai').expect;
const expect = require('chai').expect;

describe('dnsimple module', function () {
describe('#setAccessToken', function () {
Expand Down
8 changes: 4 additions & 4 deletions test/dnsimple/accounts.spec.js
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
'use strict';

var testUtils = require('../testUtils');
var dnsimple = require('../../lib/dnsimple')({
const testUtils = require('../testUtils');
const dnsimple = require('../../lib/dnsimple')({
accessToken: testUtils.getAccessToken()
});

Expand All @@ -10,15 +10,15 @@ const nock = require('nock');

describe('accounts', function () {
describe('#listAccounts', function () {
var fixture = testUtils.fixture('listAccounts/success-account.http');
const fixture = testUtils.fixture('listAccounts/success-account.http');

it('produces an account list', function (done) {
nock('https://api.dnsimple.com')
.get('/v2/accounts')
.reply(fixture.statusCode, fixture.body);

dnsimple.accounts.listAccounts().then(function (response) {
var accounts = response.data;
const accounts = response.data;
expect(accounts.length).to.eq(1);
expect(accounts[0].id).to.eq(123);
expect(accounts[0].email).to.eq('john@example.com');
Expand Down
Loading