Update with guessed and dpi protocol. (#7442)

This commit is contained in:
Nicolo Maio 2023-05-04 12:00:02 +00:00
parent 9f14c401ed
commit d5fc6f5fd9
8 changed files with 7309 additions and 7270 deletions

View file

@ -1568,9 +1568,8 @@ end
function format_confidence_badge(confidence, shorten_string)
local badge = ""
if confidence == 0 then
badge = "<span class=\"badge bg-warning\" title=\"" .. get_confidence(confidence) .. "\">" .. get_confidence(confidence, shorten_string) .. "</span>"
if confidence == 0 or confidence == -1 then
badge = "<span class=\"badge bg-warning\" title=\"" .. get_confidence(confidence) .. "\">"..get_confidence(confidence, shorten_string) .. "</span>"
elseif confidence then
badge = "<span class=\"badge bg-success\" title=\"" .. get_confidence(confidence) .. "\">" .. get_confidence(confidence, shorten_string) .. "</span>"
end