diff --git a/frontend/util.lua b/frontend/util.lua index 557f44f1a..eb242d3b8 100644 --- a/frontend/util.lua +++ b/frontend/util.lua @@ -132,7 +132,7 @@ function util.splitToChars(text) local tab = {} if text ~= nil then local prevcharcode, charcode = 0 - for uchar in string.gfind(text, "([%z\1-\127\194-\244][\128-\191]*)") do + for uchar in string.gmatch(text, "([%z\1-\127\194-\244][\128-\191]*)") do charcode = BaseUtil.utf8charcode(uchar) if prevcharcode then -- utf8 table.insert(tab, uchar)