Skip to content
Open
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
7 changes: 1 addition & 6 deletions lua/wikis/commons/Widget/Participants/Team/Roster.lua
Original file line number Diff line number Diff line change
Expand Up @@ -54,19 +54,14 @@ end
-- * If there's a non-ingame role assigned, display it after the status
-- * Returns an array of labels to display (can be multiple)
-- * Left-role:
-- * If the first role has an icon, we use that to render the left-role
-- * If not then we instead display the icon of the first ingame role with icon
-- * Display the icon of the first ingame role with icon
---@param player table
---@return string?, string[]?
local function getRoleDisplays(player)
local roles = player.extradata.roles or {}
local played = player.extradata.played

local function roleLeftDisplay()
local firstRole = roles[1]
if firstRole and firstRole.icon then
return firstRole.icon
end
for _, role in ipairs(roles) do
if role.type == RoleUtil.ROLE_TYPE.INGAME and role.icon then
return role.icon
Expand Down