mirror of
https://github.com/astaxie/beego.git
synced 2024-11-22 11:30:55 +00:00
rollback: set httponly default is false.
This commit is contained in:
parent
439b1afb85
commit
d79c297880
@ -135,12 +135,12 @@ func (output *BeegoOutput) Cookie(name string, value string, others ...interface
|
|||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
// default true
|
// default false. for session cookie default true
|
||||||
httponly := true
|
httponly := false
|
||||||
if len(others) > 4 {
|
if len(others) > 4 {
|
||||||
if v, ok := others[4].(bool); ok && !v || others[4] == nil {
|
if v, ok := others[4].(bool); ok && v {
|
||||||
// HttpOnly = false
|
// HttpOnly = true
|
||||||
httponly = false
|
httponly = true
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
|
Loading…
Reference in New Issue
Block a user