Closed matthewkeil closed 5 months ago
✔️ no performance regression detected
by benchmarkbot/action
@LesnyRumcajs You inspired me to DRY some of these implementations up. There are lots of line changed but its mostly just a refactor. Little core functionality changed. Would you be so kind as to just look at the file structure of how I refactored.
Split off from #143
Motivation In order to DRY the code the two async functions were refactored so that there is only one implementation for both sync and async versions. Makes it easier to ensure that the code for both is identical and that changes made to comply with specs were applied equally. Also makes sure that only need to test sync version but with surety that the async versions will work identically.
Note No changes were made to core implementation. Only refactored to make helper functions that could be used in both the sync and async versions of each function.
Included Change
functions.cc
intoaggregate.cc
,aggregate_verify.cc
andverify_multiple_aggregate_signatures.cc
functions-inl.h
withunwrap_public_key
andunwrap_signature
to DRY unwrapping of JS values