How do you remove an element from a TOctree?

I’m trying to use what you put above however I’m getting errors with the map, not sure what’s going on.

‘TWeakPtr::GetTypeHash’: none of the 946 overloads could convert all the argument types

USTRUCT()
struct FOctreeSemantics
{
	GENERATED_BODY()

	static TMap<FOctreeElement, FOctreeElementId2> OctreeIds;
	
	enum { MaxElementsPerLeaf = 1 };
	enum { MinInclusiveElementsPerNode = 1 };
	enum { MaxNodeDepth = 11 };
	
	typedef TInlineAllocator<MaxElementsPerLeaf> ElementAllocator;

	FORCEINLINE static FBoxSphereBounds GetBoundingBox(const FOctreeElement& Element)
	{
	 	return Element.BoxSphereBounds;
	}
	
	FORCEINLINE static void SetElementId(const FOctreeElement &Element, FOctreeElementId2 Id)
	{
		OctreeIds.Add(Element, Id); //This makes it throw the error.
	}
	
};