introduced StringUtil class with .isEmpty(String input) and .isNotEmpty(String input), to replace str != null && str.length()>0 statements

This commit is contained in:
ingmargoudt 2016-09-16 20:51:51 +02:00
parent fb15c79964
commit f1cf9e7adb
47 changed files with 132 additions and 96 deletions

View file

@ -37,6 +37,7 @@ import mage.abilities.effects.OneShotEffect;
import mage.game.Game;
import mage.game.turn.TurnMod;
import mage.players.Player;
import mage.util.StringUtil;
/**
*
@ -77,7 +78,7 @@ public class SkipNextPlayerUntapStepEffect extends OneShotEffect {
@Override
public String getText(Mode mode) {
StringBuilder sb = new StringBuilder();
if (staticText.length() > 0) {
if (StringUtil.isNotEmpty(staticText)) {
sb.append(staticText);
} else {
sb.append("target");