Return promise for empty idlist when inserting empty list insted of
crashing.