fix quality flaws
format code