Update segments.js