From a0842be8e7540515059a9fb23cd26c6dace0156c Mon Sep 17 00:00:00 2001 From: youzeliang Date: Tue, 23 Mar 2021 14:53:27 +0800 Subject: [PATCH] Update tree.go delete more "()" --- tree.go | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/tree.go b/tree.go index 74e07e84..bf1eee6b 100644 --- a/tree.go +++ b/tree.go @@ -462,7 +462,7 @@ walk: // Outer loop for walking the tree } // ... but we can't - value.tsr = (len(path) == end+1) + value.tsr = len(path) == end+1 return } @@ -474,7 +474,7 @@ walk: // Outer loop for walking the tree // No handle found. Check if a handle for this path + a // trailing slash exists for TSR recommendation n = n.children[0] - value.tsr = (n.path == "/" && n.handlers != nil) + value.tsr = n.path == "/" && n.handlers != nil } return