Trivial improvement
---
upstream.go | 5 +----
1 file changed, 1 insertion(+), 4 deletions(-)
diff --git a/upstream.go b/upstream.go
index 8843b1b..59cf827 100644
--- a/upstream.go
+++ b/upstream.go
@@ -227,10 +227,7 @@ func (uc *upstreamConn) getChannel(name string) (*upstreamChannel, error) {
}
func (uc *upstreamConn) isChannel(entity string) bool {
- if i := strings.IndexByte(uc.availableChannelTypes, entity[0]); i >= 0 {
- return true
- }
- return false
+ return strings.ContainsRune(uc.availableChannelTypes, rune(entity[0]))
}
func (uc *upstreamConn) getPendingLIST() *pendingLIST {
--
2.26.2