Reformatted code with RubyMine's Control-Alt-L