fixing add to compare button event