Skip to content

Commit

Permalink
refactor: adjust SetCookie function
Browse files Browse the repository at this point in the history
  • Loading branch information
vicanso committed Dec 10, 2018
1 parent b00be02 commit fe3cd7e
Showing 1 changed file with 2 additions and 1 deletion.
3 changes: 2 additions & 1 deletion context.go
Original file line number Diff line number Diff line change
Expand Up @@ -135,8 +135,9 @@ func (c *Context) Cookie(name string) (*http.Cookie, error) {
}

// SetCookie set the cookie for the response
func (c *Context) SetCookie(cookie *http.Cookie) {
func (c *Context) SetCookie(cookie *http.Cookie) error {
c.AddHeader(HeaderSetCookie, cookie.String())
return nil
}

// Get get the value
Expand Down

0 comments on commit fe3cd7e

Please sign in to comment.