Added destory function to logger.