Register the containing type as the owner for a RoutedCommand

Proprietary

A RoutedCommand or RoutedUICommand should be registered with the type that declares it as its owner type. Replaces a mismatched typeof(...) with the containing type.

OpenRewrite.Recipes.CSharp.CodeQuality.Wpf.UseContainingTypeAsRoutedCommandOwner
mod run . --recipe=OpenRewrite.Recipes.CSharp.CodeQuality.Wpf.UseContainingTypeAsRoutedCommandOwner

Install it once, then run it on every repository under the current directory. New to the Moderne CLI? Set it up.