Merge branch 'wip' into 1.9
This commit is contained in:
		@@ -35,7 +35,7 @@ namespace NadekoBot.Modules.Administration
 | 
				
			|||||||
 | 
					
 | 
				
			||||||
            [NadekoCommand, Usage, Description, Aliases]
 | 
					            [NadekoCommand, Usage, Description, Aliases]
 | 
				
			||||||
            [OwnerOnly]
 | 
					            [OwnerOnly]
 | 
				
			||||||
            public async Task DefPrefix([Remainder]string prefix)
 | 
					            public async Task DefPrefix([Remainder]string prefix = null)
 | 
				
			||||||
            {
 | 
					            {
 | 
				
			||||||
                if (string.IsNullOrWhiteSpace(prefix))
 | 
					                if (string.IsNullOrWhiteSpace(prefix))
 | 
				
			||||||
                {
 | 
					                {
 | 
				
			||||||
 
 | 
				
			|||||||
@@ -93,15 +93,17 @@ namespace NadekoBot.Modules.Utility
 | 
				
			|||||||
        {
 | 
					        {
 | 
				
			||||||
            var rng = new NadekoRandom();
 | 
					            var rng = new NadekoRandom();
 | 
				
			||||||
            var usrs = (await Context.Guild.GetUsersAsync()).ToArray();
 | 
					            var usrs = (await Context.Guild.GetUsersAsync()).ToArray();
 | 
				
			||||||
            var roleUsers = usrs.Where(u => u.RoleIds.Contains(role.Id)).Select(u => u.ToString())
 | 
					            var roleUsers = usrs
 | 
				
			||||||
 | 
					                .Where(u => u.RoleIds.Contains(role.Id))
 | 
				
			||||||
 | 
					                .Select(u => u.ToString())
 | 
				
			||||||
                .ToArray();
 | 
					                .ToArray();
 | 
				
			||||||
            var inroleusers = string.Join(", ", roleUsers
 | 
					
 | 
				
			||||||
                    .OrderBy(x => rng.Next())
 | 
					            await Context.Channel.SendPaginatedConfirmAsync(_client, 0, (cur) =>
 | 
				
			||||||
                    .Take(50));
 | 
					            {
 | 
				
			||||||
            var embed = new EmbedBuilder().WithOkColor()
 | 
					                return new EmbedBuilder().WithOkColor()
 | 
				
			||||||
                .WithTitle("ℹ️ " + Format.Bold(GetText("inrole_list", Format.Bold(role.Name))) + $" - {roleUsers.Length}")
 | 
					                    .WithTitle(Format.Bold(GetText("inrole_list", Format.Bold(role.Name))) + $" - {roleUsers.Length}")
 | 
				
			||||||
                .WithDescription($"```css\n[{role.Name}]\n{inroleusers}```");
 | 
					                    .WithDescription(string.Join("\n", roleUsers.Skip(cur * 20).Take(20)));
 | 
				
			||||||
            await Context.Channel.EmbedAsync(embed).ConfigureAwait(false);
 | 
					            }, roleUsers.Length, 20).ConfigureAwait(false);
 | 
				
			||||||
        }
 | 
					        }
 | 
				
			||||||
 | 
					
 | 
				
			||||||
        [NadekoCommand, Usage, Description, Aliases]
 | 
					        [NadekoCommand, Usage, Description, Aliases]
 | 
				
			||||||
 
 | 
				
			|||||||
		Reference in New Issue
	
	Block a user