fixes bug preventing calendar from being cleared completely