Moved timeRange things to cleanup method