fix bug substr
Showing
1 changed file
with
1 additions
and
1 deletions
| ... | @@ -32,7 +32,7 @@ func Substr(s string, start, length int) string { | ... | @@ -32,7 +32,7 @@ func Substr(s string, start, length int) string { |
| 32 | } | 32 | } |
| 33 | var end int | 33 | var end int |
| 34 | if (start + length) > (len(bt) - 1) { | 34 | if (start + length) > (len(bt) - 1) { |
| 35 | end = len(bt) - 1 | 35 | end = len(bt) |
| 36 | } else { | 36 | } else { |
| 37 | end = start + length | 37 | end = start + length |
| 38 | } | 38 | } | ... | ... |
-
Please register or sign in to post a comment