Skip to content

Commit

Permalink
Fix for the bug like it is done by the PD
Browse files Browse the repository at this point in the history
  • Loading branch information
DK\nim committed Mar 26, 2019
1 parent ac4500b commit fe561ce
Showing 1 changed file with 7 additions and 0 deletions.
7 changes: 7 additions & 0 deletions src/Sitecore.Support.315324/InjectCompositeComponents.cs
Original file line number Diff line number Diff line change
Expand Up @@ -12,6 +12,13 @@ public override IList<XElement> GetDevices(XElement layoutXml, ID contextDeviceI
{
var allDevices = layoutXml.Descendants("d").ToList();

#region fix
if (!allDevices.Any())
{
return new List<XElement>();
}
#endregion

var filteredDevices = FilterDevicesByDeviceId(allDevices, contextDeviceId);
if (!filteredDevices.Any() && Context.Device.FallbackDevice != null)
{
Expand Down

0 comments on commit fe561ce

Please sign in to comment.