Skip to content

Commit

Permalink
avoid generation of intermediate array (#598)
Browse files Browse the repository at this point in the history
  • Loading branch information
Uzlopak authored Jan 23, 2023
1 parent fb4f944 commit 394b315
Showing 1 changed file with 1 addition and 3 deletions.
4 changes: 1 addition & 3 deletions index.js
Original file line number Diff line number Diff line change
Expand Up @@ -161,8 +161,6 @@ function build (schema, options) {
}
}

const dependenciesName = ['validator', 'serializer', contextFunctionCode]

if (options.debugMode) {
options.mode = 'debug'
}
Expand All @@ -171,7 +169,7 @@ function build (schema, options) {
return {
validator,
serializer,
code: dependenciesName.join('\n'),
code: `validator\nserializer\n${contextFunctionCode}`,
ajv: validator.ajv
}
}
Expand Down

0 comments on commit 394b315

Please sign in to comment.