diff --git a/src/FilterLists.Services/SnapshotService/SnapshotBatchDe.cs b/src/FilterLists.Services/SnapshotService/SnapshotBatchDe.cs index 09d0e956f..bc69b55b5 100644 --- a/src/FilterLists.Services/SnapshotService/SnapshotBatchDe.cs +++ b/src/FilterLists.Services/SnapshotService/SnapshotBatchDe.cs @@ -40,7 +40,11 @@ private void AddRules() private void AddSnapshotRules() { - var snapshotRules = rules.Select(rule => new SnapshotRule {Rule = rule, AddedBySnapshot = snapshot}); + var snapshotRules = new List(); + foreach (var rule in rules) + snapshotRules.Add(new SnapshotRule {Rule = rule}); + if (snapshot.AddedSnapshotRules == null) + snapshot.AddedSnapshotRules = new List(); snapshot.AddedSnapshotRules.AddRange(snapshotRules); } }