Update conditional to allow to control user waveforms

This commit is contained in:
Aria 2025-10-15 15:14:31 -05:00
parent 35016b5847
commit fd03d1fdfb

View file

@ -472,7 +472,7 @@ export function getOscillator(s, t, value) {
}
s = s === 'user' && !partials ? 'triangle' : s;
// If no partials are given, use stock waveforms
if (!partials || !partials?.length || s === 'sine') {
if (!partials || partials?.length === 0 || s === 'sine') {
o = getAudioContext().createOscillator();
o.type = s || 'triangle';
}