Correct a bug in event-detail.js