From c21431a6cd004f2e4ac692b2ec8c56f3a4ebd036 Mon Sep 17 00:00:00 2001 From: Clint Ryan Date: Sun, 5 Jul 2015 20:18:38 +1000 Subject: [PATCH] Fixed up commenting and removed unused code --- mux.go | 7 +++---- 1 file changed, 3 insertions(+), 4 deletions(-) diff --git a/mux.go b/mux.go index f7e3c22..aa2bedf 100644 --- a/mux.go +++ b/mux.go @@ -359,9 +359,7 @@ func matchInArray(arr []string, value string) bool { return false } -type equals func(interface{}, interface{}) bool - -// matchMap returns true if the given key/value pairs exist in a given map. +// matchMapWithString returns true if the given key/value pairs exist in a given map. func matchMapWithString(toCheck map[string]string, toMatch map[string][]string, canonicalKey bool) bool { for k, v := range toCheck { // Check if key exists. @@ -388,7 +386,8 @@ func matchMapWithString(toCheck map[string]string, toMatch map[string][]string, return true } -// matchMap returns true if the given key/value pairs exist in a given map. +// matchMapWithRegex returns true if the given key/value pairs exist in a given map compiled against +// the given regex func matchMapWithRegex(toCheck map[string]*regexp.Regexp, toMatch map[string][]string, canonicalKey bool) bool { for k, v := range toCheck { // Check if key exists.