# Anzeigen ob User Email Newsletter Subscription aktiviert hat

**URL:** <https://forum.shopware.com/t/anzeigen-ob-user-email-newsletter-subscription-aktiviert-hat/100335>\
**Category:** Shopware 6 (German)\
**Created:** [30. Juni 2023 um 14:38 UTC](https://forum.shopware.com/t/anzeigen-ob-user-email-newsletter-subscription-aktiviert-hat/100335 "2023-06-30T14:38:40Z")\
**Posts on this page:** 1\
**Page:** 1

<div class="post-metadata">

**Author:** ![sascha.stieglitz](https://avatars.discourse-cdn.com/v4/letter/s/e47c2d/32.png) [@sascha.stieglitz](https://forum.shopware.com/u/sascha.stieglitz)\
**Post date:** [30. Juni 2023 um 14:38 UTC](https://forum.shopware.com/t/anzeigen-ob-user-email-newsletter-subscription-aktiviert-hat/100335/1 "2023-06-30T14:38:40Z")

</div>

Früher konnte man in Twig über `context.customer.newsletter` herausfinden, ob ein User die Newsletter Subscriptions aktiviert hat - `context.customer.newsletter` gibt es jetzt nicht mehr.

Neu ist `context.customer.newsletterSalesChannelIds` - das ist null wenn keine Newsletter aktiviert wurden. Aber man darf das wohl nicht verwenden - wenn das ins Template baut, kommt: `An exception has been thrown during the rendering of a template ("Access to property "newsletterSalesChannelIds" not allowed on entity "Shopware\Core\Checkout\Customer\CustomerEntity".").`

Wie kann ich jetzt herausfinden ob ein User die Newsletter aktiviert hat?
