import * as tsplus_module_1 from "@effect/core/io/Cause/operations/map";
import * as tsplus_module_2 from "@effect/core/stream/Channel/operations/mapErrorCause";
/**
 * Returns a new channel, which is the same as this one, except the failure
 * value of the returned channel is created by applying the specified function
 * to the failure value of this channel.
 *
 * @tsplus fluent ets/Channel mapError
 */

export function mapError_(self, f) {
  return tsplus_module_2.mapErrorCause_(self, cause => tsplus_module_1.map_(cause, f));
}
/**
 * Returns a new channel, which is the same as this one, except the failure
 * value of the returned channel is created by applying the specified function
 * to the failure value of this channel.
 *
 * @tsplus static ets/Channel/Aspects mapError
 */

export const mapError = f => self => mapError_(self, f);
//# sourceMappingURL=mapError.mjs.map