diff --git a/plugins/woocommerce-admin/client/subscriptions/index.tsx b/plugins/woocommerce-admin/client/subscriptions/index.tsx index da6b4a91be9..62546885a9f 100644 --- a/plugins/woocommerce-admin/client/subscriptions/index.tsx +++ b/plugins/woocommerce-admin/client/subscriptions/index.tsx @@ -4,10 +4,9 @@ import { __ } from '@wordpress/i18n'; import { createInterpolateElement, useState } from '@wordpress/element'; import { Button, Card, CardBody, Notice } from '@wordpress/components'; -import { PLUGINS_STORE_NAME } from '@woocommerce/data'; +import { PLUGINS_STORE_NAME, OPTIONS_STORE_NAME } from '@woocommerce/data'; import { useDispatch } from '@wordpress/data'; import { recordEvent } from '@woocommerce/tracks'; -import apiFetch from '@wordpress/api-fetch'; /** * Internal dependencies @@ -69,6 +68,7 @@ const ErrorNotice = () => { const NoThanksButton = () => { const [ isNoThanksClicked, setIsNoThanksClicked ] = useState( false ); + const { updateOptions } = useDispatch( OPTIONS_STORE_NAME ); return (