fix idGenerator.

M