Fix auth checking when looking up member avatar
This commit is contained in:
parent
ae4e8f97d0
commit
c428d95479
@ -48,7 +48,7 @@ namespace PluralKit.Bot
|
|||||||
|
|
||||||
var currentValue = location == AvatarLocation.Member ? target.AvatarUrl : guildData?.AvatarUrl;
|
var currentValue = location == AvatarLocation.Member ? target.AvatarUrl : guildData?.AvatarUrl;
|
||||||
var canAccess = location != AvatarLocation.Member || target.AvatarPrivacy.CanAccess(ctx.LookupContextFor(target));
|
var canAccess = location != AvatarLocation.Member || target.AvatarPrivacy.CanAccess(ctx.LookupContextFor(target));
|
||||||
if (string.IsNullOrEmpty(currentValue) && !canAccess)
|
if (string.IsNullOrEmpty(currentValue) || !canAccess)
|
||||||
{
|
{
|
||||||
if (location == AvatarLocation.Member)
|
if (location == AvatarLocation.Member)
|
||||||
{
|
{
|
||||||
|
Loading…
Reference in New Issue
Block a user