Reformatting and cleanup