Fixing beautification problems