Closed xdjoshuaaz closed 3 months ago
Hi there @xdjoshuaaz, thank you for this contribution! π
While we wait for one of the Core Collaborators team to have a look at your work, we wanted to let you know about that we have a checklist for some of the things we will consider during review:
Don't worry if you got something wrong. We like to think of a pull request as the start of a conversation, we're happy to provide guidance on improving your contribution.
If you realize that you might want to make some changes then you can do that by adding new commits to the branch you created for this work and pushing new commits. They should then automatically show up as updates to this pull request.
Thanks, from your friendly Umbraco GitHub bot π€ π
Hey @xdjoshuaaz, thanks for your PR π someone on the core collaborators team will review this soon!
Hi @xdjoshuaaz, thanks for this PR it works great :) Nice to have some extra guards in place
Prerequisites
No known existing issue that I could find.
Description
This PR updates the calls to ServiceDescriptor.ImplementationType by checking IsKeyedService first.
Currently, if you register a keyed service before UmbracoBuilder does its work, you'll get an exception like below (running the ComponentRuntimeTests.Start_And_Stop_Umbraco_With_Components_Enabled test):
To test & verify against this, I've registered a keyed service in the UmbracoIntegrationTest base class before UmbracoBuilder is created & used.