Skip to content

Commit

Permalink
Assign default opts
Browse files Browse the repository at this point in the history
  • Loading branch information
zachleat committed Oct 23, 2024
1 parent bd12818 commit 6f46a89
Showing 1 changed file with 2 additions and 2 deletions.
4 changes: 2 additions & 2 deletions img.js
Original file line number Diff line number Diff line change
Expand Up @@ -803,8 +803,8 @@ function setupLogger(eleventyConfig, opts) {
});
}

function queueImage(src, opts) {
let eleventyConfig = opts?.eleventyConfig;
function queueImage(src, opts = {}) {
let eleventyConfig = opts.eleventyConfig;
if(opts?.eleventyConfig && {}.propertyIsEnumerable.call(opts, "eleventyConfig")) {
delete opts.eleventyConfig;
Util.addConfig(eleventyConfig, opts);
Expand Down

0 comments on commit 6f46a89

Please sign in to comment.