diff --git a/src/generator/AutoRest.Go/Extensions.cs b/src/generator/AutoRest.Go/Extensions.cs index 39a5f82ff8..929f439207 100644 --- a/src/generator/AutoRest.Go/Extensions.cs +++ b/src/generator/AutoRest.Go/Extensions.cs @@ -435,11 +435,6 @@ public static List ValidateCompositeType(this IVariable p, string name, } } - x.AddRange(from prop in ((CompositeType)p.ModelType).Properties - where prop.IsReadOnly - select GetConstraint(string.Format("{0}.{1}", name, prop.WasFlattened() ? prop.ModelType.Name : prop.Name), - ReadOnlyConstraint, "true")); - List y = new List(); if (x.Count > 0) {