mirror of
https://github.com/lovell/sharp.git
synced 2025-12-19 15:25:07 +01:00
Switch linter from semistandard to biome
Uses the recommended rules apart from complexity/useArrowFunction, which would affect about 1700 lines of code with little benefit right now. This is something that can be addressed over time.
This commit is contained in:
@@ -1,8 +1,6 @@
|
||||
// Copyright 2013 Lovell Fuller and others.
|
||||
// SPDX-License-Identifier: Apache-2.0
|
||||
|
||||
'use strict';
|
||||
|
||||
const util = require('node:util');
|
||||
const stream = require('node:stream');
|
||||
const is = require('./is');
|
||||
@@ -205,6 +203,7 @@ const debuglog = util.debuglog('sharp');
|
||||
* @throws {Error} Invalid parameters
|
||||
*/
|
||||
const Sharp = function (input, options) {
|
||||
// biome-ignore lint/complexity/noArguments: constructor factory
|
||||
if (arguments.length === 1 && !is.defined(input)) {
|
||||
throw new Error('Invalid input');
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user