[fix] gettext: unescape \\ for ID matching (#8357)

Fixes <https://github.com/koreader/koreader/issues/8356>.
reviewable/pr8388/r1
Frans de Jonge 3 years ago committed by GitHub
parent 3483238546
commit 0aab7d7378
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23

@ -268,6 +268,8 @@ function GetText_mt.__index.changeLang(new_lang)
s = s:gsub("\\n", "\n")
-- unescape " or msgid won't match
s = s:gsub('\\"', '"')
-- unescape \\ or msgid won't match
s = s:gsub("\\\\", "\\")
data[what] = (data[what] or "") .. s
else
-- Don't save this fuzzy string and unset fuzzy for the next one.

Loading…
Cancel
Save