proper processing of dom indices