mirror of
https://github.com/lovell/sharp.git
synced 2025-12-19 07:15:08 +01:00
Replace deprecated URL parser
Fix up various linter errors
This commit is contained in:
@@ -517,7 +517,7 @@ const formats = new Map([
|
||||
function toFormat (format, options) {
|
||||
const actualFormat = formats.get(is.object(format) && is.string(format.id) ? format.id : format);
|
||||
if (!actualFormat) {
|
||||
throw is.invalidParameterError('format', `one of: ${[...formats.keys()].join(`, `)}`, format);
|
||||
throw is.invalidParameterError('format', `one of: ${[...formats.keys()].join(', ')}`, format);
|
||||
}
|
||||
return this[actualFormat](options);
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user