mirror of
https://github.com/kataras/iris.git
synced 2026-01-09 13:05:56 +00:00
Update to version 8.5.4 | Read HISTORY.md
https://github.com/kataras/iris/blob/master/HISTORY.md#th-26-october-2017--v854 Former-commit-id: 43a3b46b99085e0e0ed47b281e2f61dbb1ac6eb6
This commit is contained in:
@@ -58,6 +58,7 @@ func (r *userMemoryRepository) Exec(query Query, action Query, actionLimit int,
|
||||
ok = query(user)
|
||||
if ok {
|
||||
if action(user) {
|
||||
loops++
|
||||
if actionLimit >= loops {
|
||||
break // break
|
||||
}
|
||||
|
||||
@@ -60,6 +60,7 @@ func (r *movieMemoryRepository) Exec(query Query, action Query, actionLimit int,
|
||||
ok = query(movie)
|
||||
if ok {
|
||||
if action(movie) {
|
||||
loops++
|
||||
if actionLimit >= loops {
|
||||
break // break
|
||||
}
|
||||
|
||||
@@ -88,9 +88,9 @@ func profileByUsername(ctx iris.Context) {
|
||||
// .Params are used to get dynamic path parameters.
|
||||
username := ctx.Params().Get("username")
|
||||
ctx.ViewData("Username", username)
|
||||
// renders "./views/users/profile.html"
|
||||
// renders "./views/user/profile.html"
|
||||
// with {{ .Username }} equals to the username dynamic path parameter.
|
||||
ctx.View("users/profile.html")
|
||||
ctx.View("user/profile.html")
|
||||
}
|
||||
|
||||
func getUserByID(ctx iris.Context) {
|
||||
@@ -109,8 +109,8 @@ func createUser(ctx iris.Context) {
|
||||
ctx.StatusCode(iris.StatusInternalServerError)
|
||||
return
|
||||
}
|
||||
// renders "./views/users/create_verification.html"
|
||||
// renders "./views/user/create_verification.html"
|
||||
// with {{ . }} equals to the User object, i.e {{ .Username }} , {{ .Firstname}} etc...
|
||||
ctx.ViewData("", user)
|
||||
ctx.View("users/create_verification.html")
|
||||
ctx.View("user/create_verification.html")
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user