Removing redundant ID references in JS.