From 6c3e9151afbafcd980d64baeb629f139b268c717 Mon Sep 17 00:00:00 2001 From: Chase Pierce Date: Mon, 1 Jul 2024 10:48:37 -0600 Subject: [PATCH] further wording fixes --- README.md | 12 ++++++++++-- 1 file changed, 10 insertions(+), 2 deletions(-) diff --git a/README.md b/README.md index 73062c0..625740c 100644 --- a/README.md +++ b/README.md @@ -162,8 +162,6 @@ cookie.Set(w, "debug", "true", &cookie.Options{ }) ``` -But will need to explicitly `GetSigned` when retrieving the value. - When defaulting to signed cookies, you can still use the `unsigned` tag in the struct field to populate unsigned cookies: @@ -172,3 +170,13 @@ type MyCookies struct { Debug bool `cookie:"debug,unsigned"` } ``` + +Unsigned values can still be retrieved using the `Get` method as normal: + +```go +debug, err := cookie.Get(r, "debug") +if err != nil { + http.Error(w, err.Error(), http.StatusInternalServerError) + return +} +```