@joebigelow / wix / commits / 742d315c

Add ExpectedElement for any child type.

Sean Hall committed Jun 21, 2020 at 16:22 UTC 742d315c73a0bc592c452222d0eb6c71309276f5
1 file changed +5
src/WixToolset.Data/ErrorMessages.cs
+5
@@ -528,6 +528,11 @@ namespace WixToolset.Data
528 return Message(null, Ids.ExpectedDirectoryGotFile, "The {0} option requires a directory, but the provided path is a file: {1}", option, path);
529 }
530
531 + public static Message ExpectedElement(SourceLineNumber sourceLineNumbers, string elementName)
532 + {
533 + return Message(sourceLineNumbers, Ids.ExpectedElement, "A {0} element must have at least one child element.", elementName);
534 + }
535 +
536 public static Message ExpectedElement(SourceLineNumber sourceLineNumbers, string elementName, string childName)
537 {
538 return Message(sourceLineNumbers, Ids.ExpectedElement, "A {0} element must have at least one child element of type {1}.", elementName, childName);