updating the chord code