Don't use .startsWith use .contains instead

This is so that both internal Cobra exceptions and those errors that
pass-through Cobra and come back from C# can be captured.