mirror of
https://github.com/community-scripts/ProxmoxVE-Local.git
synced 2026-03-31 06:23:54 -04:00
Merge pull request #205 from community-scripts/fix/184
fix/184 script filtering count discrepancy
This commit is contained in:
@@ -275,7 +275,11 @@ export function DownloadedScriptsTab({ onInstallScript }: DownloadedScriptsTabPr
|
||||
scripts = scripts.filter(script => {
|
||||
if (!script) return false;
|
||||
const scriptType = (script.type ?? '').toLowerCase();
|
||||
return filters.selectedTypes.some(type => type.toLowerCase() === scriptType);
|
||||
|
||||
// Map non-standard types to standard categories
|
||||
const mappedType = scriptType === 'turnkey' ? 'ct' : scriptType;
|
||||
|
||||
return filters.selectedTypes.some(type => type.toLowerCase() === mappedType);
|
||||
});
|
||||
}
|
||||
|
||||
|
||||
@@ -303,7 +303,11 @@ export function ScriptsGrid({ onInstallScript }: ScriptsGridProps) {
|
||||
scripts = scripts.filter(script => {
|
||||
if (!script) return false;
|
||||
const scriptType = (script.type ?? '').toLowerCase();
|
||||
return filters.selectedTypes.some(type => type.toLowerCase() === scriptType);
|
||||
|
||||
// Map non-standard types to standard categories
|
||||
const mappedType = scriptType === 'turnkey' ? 'ct' : scriptType;
|
||||
|
||||
return filters.selectedTypes.some(type => type.toLowerCase() === mappedType);
|
||||
});
|
||||
}
|
||||
|
||||
|
||||
Reference in New Issue
Block a user