Skip to content

Commit 8a8cfc6

Browse files
authored
Fix doc for "then function" (#33)
1 parent 0a9d01d commit 8a8cfc6

File tree

1 file changed

+3
-1
lines changed

1 file changed

+3
-1
lines changed

src/gleam/result.gleam

Lines changed: 3 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -68,7 +68,9 @@ pub fn flatten(result: Result(Result(a, e), e)) -> Result(a, e) {
6868
}
6969
}
7070

71-
/// An alias of `map`
71+
/// Executes the function `apply` on inner value when Result is Ok, will noop
72+
/// if it is Error
73+
/// Equivalent to `map` followed by `flatten`.
7274
///
7375
pub fn then(
7476
result: Result(a, e),

0 commit comments

Comments
 (0)