change cancelled to expired and refactor