small optimization fix