fix for cancel button functionality when adding new classlist.