use ToUpper instead

This commit is contained in:
Hayden 2024-01-05 14:16:32 -06:00
parent d1b8b5eea2
commit 8dc3ca4db0
No known key found for this signature in database
GPG key ID: 17CF79474E257545
2 changed files with 9 additions and 3 deletions

View file

@ -90,10 +90,10 @@ func (cs *CurrencyRegistry) Slice() []Currency {
}
func (cs *CurrencyRegistry) IsSupported(code string) bool {
lower := strings.ToLower(code)
upper := strings.ToUpper(code)
cs.mu.RLock()
defer cs.mu.RUnlock()
_, ok := cs.registry[lower]
_, ok := cs.registry[upper]
return ok
}