Skip to content

Commit

Permalink
perf(index): use optional chaining
Browse files Browse the repository at this point in the history
Signed-off-by: Frazer Smith <[email protected]>
  • Loading branch information
Fdawgs authored Jan 2, 2025
1 parent fde5f4d commit d7bfc25
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion index.js
Original file line number Diff line number Diff line change
Expand Up @@ -43,7 +43,7 @@ const optsSchemaValidator = sharedAjvInstance.compile(optsSchema)
function envSchema (_opts) {
const opts = Object.assign({}, _opts)

if (opts.schema && opts.schema[Symbol.for('fluent-schema-object')]) {
if (opts.schema?.[Symbol.for('fluent-schema-object')]) {
opts.schema = opts.schema.valueOf()
}

Expand Down

0 comments on commit d7bfc25

Please sign in to comment.