TMap<> Access violation, when reaching HashSize in Set.h

So I do this:

if (ActiveEffectsTagsMap.Contains(Tag))

On map which looks like this:

TMap<FName, FGAEffectContainer> ActiveEffectsTagsMap;

And here is struct:

USTRUCT()
struct GAMEATTRIBUTES_API FGAEffectContainer
{
	GENERATED_USTRUCT_BODY()
public:
	TMap<FName, FGAActiveEffect> ActiveEffectsMap;//class name, active effect
};

And this causes error here:

FSetElementId FindId(KeyInitType Key) const
{
	if(HashSize)
	{

In Set.h

Though HashSize is just int32. so I guess it shouldn’t crash, it should pass and return nothing.

Problem solved.

The long story short, is that somehow (!!) this:

return effectInt->GetEffectComponent()->ApplyEffectToSelf(SpecIn);

Worked. And it shouldn’t. Beucase at the time GetEffectComponent() returned nullptr. (I forgot to reimplement function after refactor…). Yet it somehow, managed to get into ApplyEffectToSelf function.