Cleanup of simpledom.js