Fix up the WaveGenerator.js