feature: package: putout v29.0.3

This commit is contained in:
coderaiser 2023-03-08 12:26:57 +02:00
parent 14b05d1b14
commit 6b22b2412b
8 changed files with 21 additions and 9 deletions

View file

@ -78,6 +78,7 @@ const parseNameAttribute = (attribute) => {
attribute = attribute.replace('js-file-', '');
return decodeNBSP(decodeURI(atob(attribute)));
};
module.exports._parseNameAttribute = parseNameAttribute;
const parseHrefAttribute = (prefix, attribute) => {

View file

@ -6,7 +6,9 @@ CloudCmd.CommandLine = exports;
const Dialog = require('../dom/dialog');
module.exports.init = () => {};
const noop = () => {};
module.exports.init = noop;
module.exports.show = show;
module.exports.hide = hide;

View file

@ -2,7 +2,6 @@
"name": "cloudcmd",
"version": "16.13.1",
"type": "commonjs",
"commitType": "colon",
"author": "coderaiser <mnemonic.enemy@gmail.com> (https://github.com/coderaiser)",
"description": "File manager for the web with console and editor",
"homepage": "http://cloudcmd.io",
@ -127,7 +126,7 @@
"package-json": "^8.1.0",
"ponse": "^7.0.0",
"pullout": "^4.0.0",
"putout": "^28.0.0",
"putout": "^29.0.3",
"redzip": "^2.0.0",
"rendy": "^3.0.0",
"restafary": "^11.0.0",

View file

@ -107,8 +107,7 @@ function createConfig({configPath} = {}) {
};
configManager.unsubscribe = (fn) => {
// replace to off on node v10
changeEmitter.removeListener('change', fn);
changeEmitter.off('change', fn);
};
return configManager;

View file

@ -9,6 +9,7 @@ const io = require('socket.io-client');
const log = require('./log');
const env = require('../env');
const noop = () => {};
const forEachKey = currify(require('for-each-key'));
const {
@ -43,7 +44,7 @@ const rmListeners = wraptile((socket, listeners) => {
const canceled = (f) => f(null, {
status: 'canceled',
disconnect: () => {},
disconnect: noop,
});
const done = wraptile((fn, store) => fn(null, {

View file

@ -13,7 +13,10 @@ test('cloudcmd: client: listeners: getIndex: not found', (t) => {
});
test('cloudcmd: client: listeners: getIndex: found', (t) => {
const array = ['hello', 'world'];
const array = [
'hello',
'world',
];
t.equal(getIndex(array, 'world'), 1, 'should return index');
t.end();

View file

@ -6,7 +6,10 @@ const dir = '../../../client/listeners';
const getRange = require(`${dir}/get-range`);
test('cloudcmd: client: listeners: getRange: direct', (t) => {
const expected = ['hello', 'world'];
const expected = [
'hello',
'world',
];
const files = [...expected, 'how', 'come'];
const result = getRange(0, 1, files);
@ -15,7 +18,10 @@ test('cloudcmd: client: listeners: getRange: direct', (t) => {
});
test('cloudcmd: client: listeners: getRange: reverse', (t) => {
const expected = ['hello', 'world'];
const expected = [
'hello',
'world',
];
const files = [...expected, 'how', 'come'];
const result = getRange(1, 0, files);

View file

@ -11,6 +11,7 @@ const config = {
const cloudcmd = require('../..');
const configManager = cloudcmd.createConfigManager();
configManager('auth', false);
const {request} = require('serve-once')(cloudcmd, {