Preheat your oven to 375°F (190°C) and lightly grease a baking dish
In a large skillet, heat the olive oil over medium heat. Add the onion, garlic, and red bell pepper. Sauté until the onion becomes translucent and the pepper softens, about 5 minutes.
Add the butternut squash cubes to the skillet and cook for another 5 minutes, stirring occasionally.
Stir in the sweetcorn, dried thyme, dried oregano, salt, and pepper. Cook for an additional 2 minutes. Remove from heat.
In a separate bowl, combine the grated cheddar cheese, grated Parmesan cheese, breadcrumbs, and fresh parsley.
Transfer the butternut squash and sweetcorn mixture to the prepared baking dish. Spread it out evenly.
Sprinkle the cheese and breadcrumb mixture over the top of the butternut and sweetcorn mixture.
Cover the baking dish with aluminum foil and bake in the preheated oven for 25 minutes.
After 25 minutes, remove the foil and continue baking for an additional 10-15 minutes, or until the top is golden brown and the butternut squash is tender.
Once done, remove the bake from the oven and let it cool for a few minutes before serving.