This additional constraint enables adding a route to the template (and p...

...otentially to the UseMvc method) without actually implementing the actual artifact.

For example without adding an area to a controller, a route can still be added to the template.
consider merging these two steps - you're really just looking for *any* match, so first finding all the keys and then searching them isn't necessary.