Here you can find the source of exceptLast()
Array.prototype.exceptLast = function() { if (this.length <= 1) return null return this.slice(0, this.length - 1) }