Merge pull request #56 from zemirco/patch-1

[docs] Fixed syntax error in docs for struct initialization
This commit is contained in:
Matt Silverlock 2015-10-02 21:59:52 +08:00
commit f7261893ca

2
doc.go
View file

@ -135,7 +135,7 @@ a need to type-assert data when retrieving it. We'll use the Person struct we re
// Retrieve our struct and type-assert it
val := session.Values["person"]
var person &Person{}
var person = &Person{}
if person, ok := val.(*Person); !ok {
// Handle the case that it's not an expected type
}