From a19272b54de52b4b41cc4f5d3ab82a26bffd707a Mon Sep 17 00:00:00 2001 From: sebas77 Date: Mon, 9 Jul 2018 11:21:38 +0100 Subject: [PATCH] fix bug --- Svelto.ECS/EnginesRoot.Submission.cs | 8 +++----- 1 file changed, 3 insertions(+), 5 deletions(-) diff --git a/Svelto.ECS/EnginesRoot.Submission.cs b/Svelto.ECS/EnginesRoot.Submission.cs index 08dcc92..94d8b43 100644 --- a/Svelto.ECS/EnginesRoot.Submission.cs +++ b/Svelto.ECS/EnginesRoot.Submission.cs @@ -65,12 +65,10 @@ namespace Svelto.ECS ITypeSafeDictionary dbDic; FasterDictionary groupedGroup = null; if (groupDB.TryGetValue(entityViewTypeSafeDictionary.Key, out dbDic) == false) - { dbDic = groupDB[entityViewTypeSafeDictionary.Key] = entityViewTypeSafeDictionary.Value.Create(); - - if (_groupedGroups.TryGetValue(entityViewTypeSafeDictionary.Key, out groupedGroup) == false) - groupedGroup = _groupedGroups[entityViewTypeSafeDictionary.Key] = new FasterDictionary(); - } + + if (_groupedGroups.TryGetValue(entityViewTypeSafeDictionary.Key, out groupedGroup) == false) + groupedGroup = _groupedGroups[entityViewTypeSafeDictionary.Key] = new FasterDictionary(); //type safe copy dbDic.FillWithIndexedEntities(entityViewTypeSafeDictionary.Value);