fixing flaws