refactor: #904 should reset iterator only once

This commit is contained in:
Dilshan Sandhu
2024-04-27 02:20:34 +05:30
parent d3a37e96a9
commit d53261d642

View File

@ -259,8 +259,6 @@ func sliceGraphemeClusters(g *uniseg.Graphemes, start, end int) *uniseg.Grapheme
}
g.Reset()
return uniseg.NewGraphemes(output)
}
@ -287,8 +285,6 @@ func getGraphemeLength(g *uniseg.Graphemes) int {
output++
}
g.Reset()
return output
}