Merge branch 'master' of https://github.com/ngerakines/gin into ngerakines-master

It adds MustGet() method in context.

Conflicts:
	examples/example_basic.go
This commit is contained in:
Manu Mtz-Almeida
2014-07-04 17:05:56 +02:00
3 changed files with 22 additions and 18 deletions

View File

@ -38,7 +38,7 @@ func main() {
}))
authorized.POST("admin", func(c *gin.Context) {
user := c.Get(gin.AuthUserKey).(string)
user := c.MustGet(gin.AuthUserKey).(string)
// Parse JSON
var json struct {