[SPARK-3362][SQL] bug in casewhen resolve

Current implementation will ignore else val type.