Remove all space
This commit is contained in:
parent
91f35592f4
commit
bb68efc27d
@ -108,6 +108,7 @@ public class Preference implements Commande {
|
|||||||
GuildPreferenceEntity pref = getPreference(event.getGuild());
|
GuildPreferenceEntity pref = getPreference(event.getGuild());
|
||||||
switch (key){
|
switch (key){
|
||||||
case "anti_spam":
|
case "anti_spam":
|
||||||
|
value = value.replaceAll(" ", "");
|
||||||
if(value.toLowerCase().equals("true") || value.toLowerCase().equals("false")){
|
if(value.toLowerCase().equals("true") || value.toLowerCase().equals("false")){
|
||||||
boolean result = Boolean.parseBoolean(value);
|
boolean result = Boolean.parseBoolean(value);
|
||||||
pref.setAntiSpam(result);
|
pref.setAntiSpam(result);
|
||||||
@ -125,6 +126,7 @@ public class Preference implements Commande {
|
|||||||
|
|
||||||
|
|
||||||
case "default_role":
|
case "default_role":
|
||||||
|
value = value.replaceAll(" ", "");
|
||||||
if(value.toLowerCase().equals("true") || value.toLowerCase().equals("false")){
|
if(value.toLowerCase().equals("true") || value.toLowerCase().equals("false")){
|
||||||
boolean result = Boolean.parseBoolean(value);
|
boolean result = Boolean.parseBoolean(value);
|
||||||
pref.setDefaultRole(result);
|
pref.setDefaultRole(result);
|
||||||
@ -163,6 +165,7 @@ public class Preference implements Commande {
|
|||||||
|
|
||||||
break;
|
break;
|
||||||
case "welcome":
|
case "welcome":
|
||||||
|
value = value.replaceAll(" ", "");
|
||||||
if(value.toLowerCase().equals("true") || value.toLowerCase().equals("false")){
|
if(value.toLowerCase().equals("true") || value.toLowerCase().equals("false")){
|
||||||
boolean result = Boolean.parseBoolean(value);
|
boolean result = Boolean.parseBoolean(value);
|
||||||
pref.setWelcome(result);
|
pref.setWelcome(result);
|
||||||
|
Loading…
Reference in New Issue
Block a user