fixed not all code paths being evaluated