Compare commits

..

2 commits

Author SHA1 Message Date
d09c21e3c8 unnecessary indirection 2023-12-30 16:35:21 +00:00
d79f7cae89 Merge tag 'v0.2.0' into develop
overall improvements
2023-12-30 16:05:27 +00:00

View file

@ -10,7 +10,7 @@ export async function map_concurrent<In, Out>(
map_fn: (input: In) => Promise<Out | null>, map_fn: (input: In) => Promise<Out | null>,
): Promise<Map<In, Out | null>> { ): Promise<Map<In, Out | null>> {
// apply map_fn to inputs // apply map_fn to inputs
const outputs = await Promise.all([...inputs].map((input) => map_fn(input))); const outputs = await Promise.all([...inputs].map(map_fn));
// create map object // create map object
return new Map<In, Out | null>( return new Map<In, Out | null>(