From a2b5961f647f1f9677d11fb5ebe7d1514fb6d1c6 Mon Sep 17 00:00:00 2001 From: Philipp Gesang Date: Sun, 21 Nov 2021 20:14:40 +0100 Subject: fix references to unicode apis Where the hell is unicode.upper? --- src/trans_tables_sr.lua | 5 ++++- 1 file changed, 4 insertions(+), 1 deletion(-) (limited to 'src/trans_tables_sr.lua') diff --git a/src/trans_tables_sr.lua b/src/trans_tables_sr.lua index 4f549c5..92162df 100644 --- a/src/trans_tables_sr.lua +++ b/src/trans_tables_sr.lua @@ -130,7 +130,10 @@ if not translit.done_serbian then } local P = lpeg.P - local sub, upper = unicode.utf8.sub, unicode.utf8.upper + local utf8 = unicode and unicode.utf8 or utf or utf8 + local sub = utf8.sub + local toupper = lpeg.patterns.toupper + local upper = function (s) return lpegmatch (toupper, s) end local p_tocy, p_i_tocy, p_tolt, p_i_tolt -- cgit v1.2.3