Fixes top menu in Historical DB

This commit is contained in:
Matteo Biscosi 2024-07-03 16:11:25 +02:00
parent 33c60dace4
commit fd9bfe0afb
5 changed files with 16 additions and 12 deletions

View file

@ -1000,7 +1000,11 @@ function format_portidx_name(device_ip, portidx, short_version, shorten_string)
if short_version then
local name = port_info["name"]
if shorten_string then
name = shortenString(name)
if type(shorten_string) == "number" then
name = shortenString(name, shorten_string)
else
name = shortenString(name)
end
end
idx_name = string.format('%s', name);
else