Skip to content

Commit

Permalink
Fixed bug. (entry nil map)
Browse files Browse the repository at this point in the history
  • Loading branch information
guerillagrow committed Jul 18, 2018
1 parent 1180ddd commit ae10811
Showing 1 changed file with 4 additions and 1 deletion.
5 changes: 4 additions & 1 deletion session/sess_file.go
Original file line number Diff line number Diff line change
Expand Up @@ -105,7 +105,10 @@ func (fs *FileSessionStore) SessionRelease(w http.ResponseWriter) {
// !HOT
buf := &bytes.Buffer{}
io.Copy(buf, f)
od, _ := DecodeGob(buf.Bytes())
od, dgerr := DecodeGob(buf.Bytes())
if dgerr != nil {
od = make(map[interface{}]interface{})
}
var b []byte

for k, v := range fs.values {
Expand Down

0 comments on commit ae10811

Please sign in to comment.