Update merge.idex.js

Keeping recursion to occur on DOM element