import * as tsplus_module_1 from "@effect/core/io/Fiber/operations/collectAll";
import * as tsplus_module_2 from "@effect/core/io/Effect/operations/ensuringChildren";
/**
 * Acts on the children of this fiber (collected into a single fiber),
 * guaranteeing the specified callback will be invoked, whether or not this
 * effect succeeds.
 *
 * @tsplus fluent ets/Effect ensuringChild
 */

export function ensuringChild_(self, f, __tsplusTrace) {
  return tsplus_module_2.ensuringChildren_(self, children => f(tsplus_module_1.collectAll(children)), __tsplusTrace);
}
/**
 * Acts on the children of this fiber (collected into a single fiber),
 * guaranteeing the specified callback will be invoked, whether or not
 * this effect succeeds.
 *
 * @tsplus static ets/Effect/Aspects ensuringChild
 */

export const ensuringChild = (f, __tsplusTrace) => self => ensuringChild_(self, f, __tsplusTrace);
//# sourceMappingURL=ensuringChild.mjs.map