From 47bebe42c38bd3b802a74d244f9f83ad4695a888 Mon Sep 17 00:00:00 2001 From: "Douglas M." Date: Thu, 4 Apr 2024 18:03:56 +0200 Subject: [PATCH] docs: fix `try` examples --- src/remote_data.gleam | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/src/remote_data.gleam b/src/remote_data.gleam index 880cb32..87dd77c 100644 --- a/src/remote_data.gleam +++ b/src/remote_data.gleam @@ -104,17 +104,17 @@ pub fn map_error( /// /// ## Examples /// ```gleam -/// and_then(over: Success(42), with: fn(x) { Success(x * 2) }) +/// try(over: Success(42), with: fn(x) { Success(x * 2) }) /// // -> Success(84) /// ``` /// /// ```gleam -/// and_then(over: Failure("error"), with: fn(x) { Success(x * 2) }) +/// try(over: Failure("error"), with: fn(x) { Success(x * 2) }) /// // -> Failure("error") /// ``` /// /// ```gleam -/// and_then(over: Success(42), with: fn(x) { Failure("error") }) +/// try(over: Success(42), with: fn(x) { Failure("error") }) /// // -> Failure("error") /// ``` pub fn try(