change chain

This commit is contained in:
Rowan 2025-04-17 18:30:43 -05:00
parent dfe823f53a
commit ff7da1c590

View file

@ -116,7 +116,7 @@ export const ap = curry(dispatch(['fantasy-land/ap', 'ap'],
/**
* @template A, B
* @template {Morphism<A, B>} Ap
* @param {Morphism<A, B>} f
* @param {Ap} f
* @param {{ ap: Ap } | Ap} a
*/
(f, a) => {
@ -131,7 +131,7 @@ export const ap = curry(dispatch(['fantasy-land/ap', 'ap'],
}))
export const chain = curry(dispatch(['fantasy-land/chain', 'chain'],
(f, a) => a.map(f)
(f, a) => f(a)
))
export const map = curry(dispatch(['fantasy-land/map', 'map'],