Skip to content

Commit

Permalink
Fixes #9993 - Cannot save empty image in Grid
Browse files Browse the repository at this point in the history
  • Loading branch information
nul800sebastiaan committed Mar 17, 2021
1 parent 1570d49 commit cf4c163
Showing 1 changed file with 2 additions and 2 deletions.
4 changes: 2 additions & 2 deletions src/Umbraco.Web/PropertyEditors/GridPropertyEditor.cs
Original file line number Diff line number Diff line change
Expand Up @@ -202,8 +202,8 @@ public IEnumerable<UmbracoEntityReference> GetReferences(object value)
_richTextPropertyValueEditor.GetReferences(x.Value)))
yield return umbracoEntityReference;

foreach (var umbracoEntityReference in mediaValues.SelectMany(x =>
_mediaPickerPropertyValueEditor.GetReferences(x.Value["udi"])))
foreach (var umbracoEntityReference in mediaValues.Where(x => x.Value.HasValues)
.SelectMany(x => _mediaPickerPropertyValueEditor.GetReferences(x.Value["udi"])))
yield return umbracoEntityReference;
}
}
Expand Down

0 comments on commit cf4c163

Please sign in to comment.