mirror of
https://github.com/walles/moar.git
synced 2024-11-12 17:22:53 +03:00
Fix an off-by-one error
This commit is contained in:
parent
d7dacd4dae
commit
abe8f37eaf
@ -49,7 +49,7 @@ func _StyledStringsFromString(s string) []_StyledString {
|
||||
for _, match := range matches {
|
||||
end = match[0]
|
||||
|
||||
if end > beg+1 {
|
||||
if end > beg {
|
||||
// Otherwise the string is empty, no point for us in that
|
||||
styledStrings = append(styledStrings, _StyledString{
|
||||
String: s[beg:end],
|
||||
|
Loading…
Reference in New Issue
Block a user