fix batch insert error when empty lists are passed in