) || "";
                    let valB = rowB.querySelector(`[data-column="${column}"]`)?.innerText.trim() || "";

                    // Special handling for Graph API Permissions (sort by count)
                    if (column === "graph_api_permissions") {
                        valA = valA.split(",").length; // Count of unique permissions
                        valB = valB.split(",").length;
                        return currentSortOrder === "asc" ? valA - valB : valB - valA;
                    }

   