condensed if/else