Merge two if conditions, allow to decrese the level of indentation of