Skip to content

Commit cc889bd

Browse files
committed
chore: lint
1 parent 43edba8 commit cc889bd

Some content is hidden

Large Commits have some content hidden by default. Use the searchbox below for content that may be hidden.

48 files changed

+64
-62
lines changed

.github/workflows/nodejs.yml

Lines changed: 0 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -9,7 +9,6 @@ jobs:
99
strategy:
1010
matrix:
1111
node-version:
12-
- 20.x
1312
- 22.x
1413
- 24.x
1514
- 25.x

.putout.json

Lines changed: 3 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -46,6 +46,9 @@
4646
},
4747
"vim.js": {
4848
"merge-duplicate-functions": "off"
49+
},
50+
"common": {
51+
"nodejs/declare": "off"
4952
}
5053
}
5154
}

.webpack/js.js

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -31,7 +31,7 @@ const devtool = isDev ? 'eval' : 'source-map';
3131
const notEmpty = (a) => a;
3232
const clean = (array) => array.filter(notEmpty);
3333

34-
const noParse = (a) => /\.spec\.js$/.test(a);
34+
const noParse = (a) => a.endsWith('.spec.js');
3535
const options = {
3636
babelrc: true,
3737
};

bin/cloudcmd.mjs

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -3,7 +3,7 @@
33
import process from 'node:process';
44
import {createRequire} from 'node:module';
55
import {promisify} from 'node:util';
6-
import tryToCatch from 'try-to-catch';
6+
import {tryToCatch} from 'try-to-catch';
77
import {createSimport} from 'simport';
88
import parse from 'yargs-parser';
99
import exit from '../server/exit.js';

bin/release.mjs

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -2,7 +2,7 @@
22

33
import {promisify} from 'node:util';
44
import process from 'node:process';
5-
import tryToCatch from 'try-to-catch';
5+
import {tryToCatch} from 'try-to-catch';
66
import {createSimport} from 'simport';
77
import minor from 'minor';
88
import _place from 'place';

client/client.js

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -7,7 +7,7 @@ const Emitify = require('emitify');
77
const inherits = require('inherits');
88
const rendy = require('rendy');
99
const load = require('load.js');
10-
const tryToCatch = require('try-to-catch');
10+
const {tryToCatch} = require('try-to-catch');
1111
const {addSlashToEnd} = require('format-io');
1212
const pascalCase = require('just-pascal-case');
1313
const currify = require('currify');

client/dom/current-file.js

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -296,7 +296,7 @@ module.exports.isCurrentIsDir = (currentFile) => {
296296
const path = DOM.getCurrentPath(current);
297297
const fileType = DOM.getCurrentType(current);
298298

299-
const isZip = /\.zip$/.test(path);
299+
const isZip = path.endsWith('.zip');
300300
const isDir = /^directory(-link)?/.test(fileType);
301301

302302
return isDir || isZip;

client/dom/current-file.spec.js

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -291,7 +291,7 @@ function getDOM(overrides = {}) {
291291
getByDataName = stub(),
292292
isContainClass = stub(),
293293
getCurrentType = stub(),
294-
getCurrentPath = stub(),
294+
getCurrentPath = stub().returns(''),
295295
} = overrides;
296296

297297
return {

client/dom/dialog.js

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,6 @@
11
'use strict';
22

3-
const tryToCatch = require('try-to-catch');
3+
const {tryToCatch} = require('try-to-catch');
44

55
const {
66
alert,

client/dom/dom-tree.spec.js

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -2,7 +2,7 @@
22

33
const test = require('supertape');
44
const {create} = require('auto-globals');
5-
const tryCatch = require('try-catch');
5+
const {tryCatch} = require('try-catch');
66

77
const {isContainClass} = require('./dom-tree');
88

0 commit comments

Comments
 (0)