mirror of
https://github.com/netbirdio/netbird.git
synced 2026-10-24 14:29:07 +02:00
only restrictable roles get restricted peers views
This commit is contained in:
@@ -59,7 +59,7 @@ func (am *DefaultAccountManager) GetPeers(ctx context.Context, accountID, userID
|
|||||||
return nil, fmt.Errorf("failed to get account settings: %w", err)
|
return nil, fmt.Errorf("failed to get account settings: %w", err)
|
||||||
}
|
}
|
||||||
|
|
||||||
if settings.RegularUsersViewBlocked {
|
if user.IsRestrictable() && settings.RegularUsersViewBlocked {
|
||||||
return []*nbpeer.Peer{}, nil
|
return []*nbpeer.Peer{}, nil
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|||||||
Reference in New Issue
Block a user