Repository: gin-gonic/gin (language: go)

Issue:
RedirectTrailingSlash not working if there are more than one child route
## Description
RedirectTrailingSlash not working if there are more than two child route.

## How to reproduce
```
package main

import (
	"github.com/gin-gonic/gin"
)

func main() {
	g := gin.New()
        router := g.Group("/v1")
	router.GET("/hello", dummyFunction)
        router.GET("/hello/a", dummyFunction)
        router.GET("/hello/b", dummyFunction)
	g.Run(":9000")
}
```

## Expectations
```
$ curl http://localhost:8201/hello/ should redirect [301] to {{URL}}/hello 
```
## Actual result
Getting 404

The same works if there is only one child /hello/a 
## Environment

- go version: go version go1.13.3 linux/amd64
- gin version (or commit ref):  v1.5.0
- operating system: ubuntu 16.04



Discussion / hints:
Here's what I think is happening.

`/hello/` is returning a 404 because the router knows there are routes that live under /hello/

I guessing the fix would be:  

if there are routes under `/hello/` and you have a trailing slash, and theres nothing after the trailing slash, redirect. 


Fix patch:
diff --git a/tree.go b/tree.go
index 956bf4dd3c..3f34b8ee82 100644
--- a/tree.go
+++ b/tree.go
@@ -107,7 +107,8 @@ func countSections(path string) uint16 {
 type nodeType uint8
 
 const (
-	root nodeType = iota + 1
+	static nodeType = iota
+	root
 	param
 	catchAll
 )
@@ -173,6 +174,7 @@ walk:
 			child := node{
 				path:      n.path[i:],
 				wildChild: n.wildChild,
+				nType:     static,
 				indices:   n.indices,
 				children:  n.children,
 				handlers:  n.handlers,
@@ -604,6 +606,11 @@ walk: // Outer loop for walking the tree
 				return
 			}
 
+			if path == "/" && n.nType == static {
+				value.tsr = true
+				return
+			}
+
 			// No handle found. Check if a handle for this path + a
 			// trailing slash exists for trailing slash recommendation
 			for i, c := range []byte(n.indices) {


Test patch:
diff --git a/tree_test.go b/tree_test.go
index 085b58037b..2005738ec6 100644
--- a/tree_test.go
+++ b/tree_test.go
@@ -684,6 +684,26 @@ func TestTreeRootTrailingSlashRedirect(t *testing.T) {
 	}
 }
 
+func TestRedirectTrailingSlash(t *testing.T) {
+	var data = []struct {
+		path string
+	}{
+		{"/hello/:name"},
+		{"/hello/:name/123"},
+		{"/hello/:name/234"},
+	}
+
+	node := &node{}
+	for _, item := range data {
+		node.addRoute(item.path, fakeHandler("test"))
+	}
+
+	value := node.getValue("/hello/abx/", nil, getSkippedNodes(), false)
+	if value.tsr != true {
+		t.Fatalf("want true, is false")
+	}
+}
+
 func TestTreeFindCaseInsensitivePath(t *testing.T) {
 	tree := &node{}