Cleaning up code (for compare.html)