Fix "code smells"