Finished porting memPrefixTree insert