Revert some incorrect clean-up changes on calender plugin