Skip to content

Commit a476671

Browse files
committed
Fix GetterSetterToProperty pass heuristic to also detect “to” as a verb.
1 parent 0be5084 commit a476671

File tree

1 file changed

+1
-1
lines changed

1 file changed

+1
-1
lines changed

src/Generator/Passes/GetterSetterToPropertyPass.cs

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -115,7 +115,7 @@ private IEnumerable<Property> CleanUp(Class @class, List<Property> properties)
115115
Match(firstWord, new[] { "get", "is", "has" }))
116116
continue;
117117

118-
if (Match(firstWord, new[] { "to", "new" }) ||
118+
if (Match(firstWord, new[] { "to", "new", "on" }) ||
119119
verbs.Contains(firstWord))
120120
{
121121
property.GetMethod.GenerationKind = GenerationKind.Generate;

0 commit comments

Comments
 (0)