Skip to content

Commit

Permalink
CloneModelView: Verify the view is not there before creation to suppoโ€ฆ
Browse files Browse the repository at this point in the history
โ€ฆrt special cases, e.g ModelDifference #908
  • Loading branch information
apobekiaris committed Feb 20, 2022
1 parent 810587e commit 46bea88
Showing 1 changed file with 1 addition and 0 deletions.
1 change: 1 addition & 0 deletions src/Modules/CloneModelView/CloneModelViewService.cs
Original file line number Diff line number Diff line change
Expand Up @@ -68,6 +68,7 @@ static void AssignAsDefaultView(this CloneModelViewAttribute cloneModelViewAttri

static void GenerateModel(this IModelViews views, IModelClass classInfo){
var cloneViewAttributes = classInfo.TypeInfo.FindAttributes<CloneModelViewAttribute>(false)
.Where(attribute => views[attribute.ViewId]==null)
.OrderBy(viewAttribute => viewAttribute.ViewType);
foreach (var cloneViewAttribute in cloneViewAttributes){
var modelView = views.NewModelView( cloneViewAttribute, classInfo);
Expand Down

0 comments on commit 46bea88

Please sign in to comment.