Changed dets:insert by dets:insert_new