mirror of
https://github.com/koreader/koreader.git
synced 2025-08-10 00:52:38 +00:00
GetText: fix crash if a value is used as unique value and as singular/plural (#11643)
Concretely 1 second, %1 seconds since #11549 added `1 second` all by itself.
This commit is contained in:
@@ -58,7 +58,7 @@ Returns a translation.
|
||||
local translation = _("A meaningful message.")
|
||||
--]]
|
||||
function GetText_mt.__call(gettext, msgid)
|
||||
return gettext.translation[msgid] or gettext.wrapUntranslated(msgid)
|
||||
return gettext.translation[msgid] and gettext.translation[msgid][0] or gettext.translation[msgid] or gettext.wrapUntranslated(msgid)
|
||||
end
|
||||
|
||||
local function c_escape(what_full, what)
|
||||
|
||||
Reference in New Issue
Block a user