Browse Source

Fixed up commenting and removed unused code

pull/100/head
Clint Ryan 11 years ago
parent
commit
c21431a6cd
  1. 7
      mux.go

7
mux.go

@ -359,9 +359,7 @@ func matchInArray(arr []string, value string) bool {
return false return false
} }
type equals func(interface{}, interface{}) bool // matchMapWithString returns true if the given key/value pairs exist in a given map.
// matchMap 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 { func matchMapWithString(toCheck map[string]string, toMatch map[string][]string, canonicalKey bool) bool {
for k, v := range toCheck { for k, v := range toCheck {
// Check if key exists. // Check if key exists.
@ -388,7 +386,8 @@ func matchMapWithString(toCheck map[string]string, toMatch map[string][]string,
return true 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 { func matchMapWithRegex(toCheck map[string]*regexp.Regexp, toMatch map[string][]string, canonicalKey bool) bool {
for k, v := range toCheck { for k, v := range toCheck {
// Check if key exists. // Check if key exists.

Loading…
Cancel
Save