Fix incorrect bookkeeping of the last built L1ID