Files
projet_gestion_commande/frontend-admin/node_modules/expo-image-picker/ios/ImagePickerUtils.swift
T
2026-02-07 22:33:02 +01:00

17 lines
415 B
Swift

// Copyright 2024-present 650 Industries. All rights reserved.
/**
Asynchronously maps the given sequence (sequentially).
*/
func asyncMap<ItemsType: Sequence, ResultType>(
_ items: ItemsType,
_ transform: (ItemsType.Element) async throws -> ResultType
) async rethrows -> [ResultType] {
var values = [ResultType]()
for item in items {
try await values.append(transform(item))
}
return values
}