Closed sidshrivastav closed 4 years ago
Fixed in version 2.4.3 just published to npm Sorry for delay.
Since the default for ensureSecureImageRequest
is true
not false
, your solution wouldn't work. Here's what I did instead, it's a bit cleaner than what was there before.
const opts = Object.assign(
// defaults
{
userAgent: 'MetadataScraper',
fromEmail: 'example@example.com',
maxRedirects: 10,
timeout: 10000,
descriptionLength: 750,
ensureSecureImageRequest: true,
sourceMap: {},
decode: undefined,
encode: undefined
},
// options passed in override defaults
options
)
Changes implementation by using logical and.
Logical AND (&&)
Logical OR (||)