Update to use swift dictionary on insert call