From 0ac845078ca01a1755571c53d7a8e7995b96e40d Mon Sep 17 00:00:00 2001 From: kzh125 Date: Tue, 26 Jan 2021 09:57:54 +0800 Subject: [PATCH] docs: fix incorrect generated code in example (#277) Should be "return foobarbaz.Baz{}, err" --- docs/guide.md | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/docs/guide.md b/docs/guide.md index eb5f70e9..dc1b42e7 100644 --- a/docs/guide.md +++ b/docs/guide.md @@ -165,7 +165,7 @@ func initializeBaz(ctx context.Context) (foobarbaz.Baz, error) { bar := foobarbaz.ProvideBar(foo) baz, err := foobarbaz.ProvideBaz(ctx, bar) if err != nil { - return 0, err + return foobarbaz.Baz{}, err } return baz, nil }