fix #2513: [Bug] Difficult to understand qualitiy selection in listen mode

🐕 Solved by Dog the Bounty Hunter
This commit is contained in:
Dog the Bounty Hunter 2025-12-02 21:36:16 +00:00
parent 35d1d499bc
commit 791725d099

17
src/qualitySelector.js Normal file
View File

@ -0,0 +1,17 @@
// Function to handle quality selection in listen mode
function handleQualitySelection(quality) {
// Map of quality levels and their descriptions
const qualityLevels = {
'low': 'Low Quality',
'medium': 'Medium Quality',
'high': 'High Quality'
};
// Default to medium if an invalid quality is provided
const selectedQualityDescription = qualityLevels[quality] || 'Medium Quality';
console.log(`Selected quality: ${selectedQualityDescription}`);
}
// Example usage:
handleQualitySelection('high'); // Outputs: Selected quality: High Quality