Code now merges if add throws an IntegrityError from a duplicate key.