mirror of
https://github.com/miniflux/v2.git
synced 2025-08-01 17:38:37 +00:00
Broaden an error condition
`http.ErrNoCookie` isn't the only possible error value.
This commit is contained in:
parent
7967ce4df2
commit
60e1d9e361
1 changed files with 1 additions and 1 deletions
|
@ -8,7 +8,7 @@ import "net/http"
|
|||
// CookieValue returns the cookie value.
|
||||
func CookieValue(r *http.Request, name string) string {
|
||||
cookie, err := r.Cookie(name)
|
||||
if err == http.ErrNoCookie {
|
||||
if err != nil {
|
||||
return ""
|
||||
}
|
||||
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue