redis
redis copied to clipboard
interface conversion: interface {} is map[string]interface {}, not url.Values
since I change the store to redis. this code cannot work
store, err := session.Start(nil, w, r)
if err != nil {
return
}
if r.Form == nil {
r.ParseForm()
}
store.Set("RequestForm", r.Form)
store.Save()
...
store, err := session.Start(nil, w, r)
if err != nil {
return
}
form, ok := store.Get("RequestForm")
if !ok {
return
}
clientID := form.(url.Values).Get("client_id")
occur this error
interface conversion: interface {} is map[string]interface {}, not url.Values.
how can i fix this? thx
Same here. Everything seems to be marshaled as map[string]interface{} and therefore does not preserve the original types.