= Saving allowed roles per guild

This commit is contained in:
Matthew Cech
2019-05-06 00:21:17 -07:00
parent 380fdbc605
commit 5eddc4645e
9 changed files with 110 additions and 16 deletions
+3 -3
View File
@@ -15,16 +15,16 @@ public class CommandGuildRoleList extends Command
public void OnRun(KittyGuild guild, KittyChannel channel, KittyUser user, UserInput input, Response res)
{
String roles = "";
if(guild.allowedRole.isEmpty())
if(guild.roleList.isEmpty())
{
res.Call(String.format(LocStrings.Stub("GuildRoleListEmpty")));
return;
}
for(int i = 0; i < guild.allowedRole.size(); i++)
for(int i = 0; i < guild.roleList.size(); i++)
{
if(i > 0)
roles += " and ";
roles += guild.allowedRole.get(i);
roles += guild.roleList.get(i);
}
res.Call(String.format(LocStrings.Stub("GuildRoleListOutput"), roles));
}