File tree Expand file tree Collapse file tree 2 files changed +3
-6
lines changed
Expand file tree Collapse file tree 2 files changed +3
-6
lines changed Original file line number Diff line number Diff line change @@ -929,15 +929,13 @@ async function squooshMinify(original, options) {
929929
930930 const { encodeOptions = { } } = squooshOptions ;
931931
932- if ( ! ( /** @type { SquooshEncodeOptions } */ ( encodeOptions ) [ targetCodec ] ) ) {
933- /** @type { SquooshEncodeOptions } */ ( encodeOptions ) [ targetCodec ] = { } ;
932+ if ( ! encodeOptions [ targetCodec ] ) {
933+ encodeOptions [ targetCodec ] = { } ;
934934 }
935935
936936 try {
937937 await image . encode ( {
938- [ targetCodec ] : ( encodeOptions ) [
939- targetCodec
940- ] ,
938+ [ targetCodec ] : encodeOptions [ targetCodec ] ,
941939 } ) ;
942940 } catch ( error ) {
943941 await imagePool . close ( ) ;
Original file line number Diff line number Diff line change @@ -61,7 +61,6 @@ async function worker(options) {
6161 warnings : [ ] ,
6262 errors : [ ] ,
6363 info : {
64- ...options . info ,
6564 sourceFilename :
6665 options . info &&
6766 typeof options . info === "object" &&
You can’t perform that action at this time.
0 commit comments