diff --git a/utils.go b/utils.go index d1afd44f..8db8db4e 100644 --- a/utils.go +++ b/utils.go @@ -32,7 +32,7 @@ func Substr(s string, start, length int) string { } var end int if (start + length) > (len(bt) - 1) { - end = len(bt) - 1 + end = len(bt) } else { end = start + length }