Clean up main, extract getForecast