Reformatted code using Intellj default formatting.