Cleaned up Main