Reformating JS to aid in analysis