if clause for helper