mirror of
https://github.com/PluralKit/PluralKit.git
synced 2026-02-10 07:47:53 +00:00
Add -all flag on system and group cards (#216)
* Show group count on stats card * Add -all flag on system and group cards Shows full count, including private members. * fix stuff broken by merging conflicts
This commit is contained in:
parent
5ba89d32fc
commit
42b70cde9a
5 changed files with 18 additions and 7 deletions
|
|
@ -44,5 +44,14 @@ namespace PluralKit.Bot
|
|||
ctx.PopArgument();
|
||||
return subject;
|
||||
}
|
||||
|
||||
public static bool MatchPrivateFlag(this Context ctx, LookupContext pctx)
|
||||
{
|
||||
var privacy = true;
|
||||
if (ctx.MatchFlag("a", "all")) privacy = false;
|
||||
if (pctx == LookupContext.ByNonOwner && !privacy) throw Errors.LookupNotAllowed;
|
||||
|
||||
return privacy;
|
||||
}
|
||||
}
|
||||
}
|
||||
Loading…
Add table
Add a link
Reference in a new issue