Fix: JavaScript error in variations.js