did fixes for if block