1
0
mirror of https://github.com/kataras/iris.git synced 2025-12-24 05:17:03 +00:00

Add history for v3.0.0.-beta.2. Some fixes to subdomains listening on local 127.0.0.1. Change GetURI to ParseURI

Examples and e-book updated also.
This commit is contained in:
Makis Maropoulos
2016-06-04 23:07:19 +03:00
parent 1a433e34d5
commit 26ef396959
10 changed files with 109 additions and 91 deletions

View File

@@ -25,11 +25,10 @@ func (ctx *Context) Redirect(urlToRedirect string, statusHeader ...int) {
// RedirectTo does the same thing as Redirect but instead of receiving a uri or path it receives a route name
func (ctx *Context) RedirectTo(routeName string, args ...interface{}) {
s, ok := ctx.station.RouteByName(routeName).Parse(args...)
if ok {
s := ctx.station.RouteByName(routeName).ParseURI(args...)
if s != "" {
ctx.Redirect(s, StatusFound)
}
}
// Error handling