Skip to content

Commit

Permalink
Merge pull request #8967 from google/infra/8826-followup-fix-resolve-…
Browse files Browse the repository at this point in the history
…selects

Replace __experimentalResolveSelect with resolveSelect.
  • Loading branch information
tofumatt committed Jul 4, 2024
2 parents d1f8bea + 56ec1a7 commit 12e537d
Show file tree
Hide file tree
Showing 3 changed files with 3 additions and 9 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -25,7 +25,7 @@ import { __ } from '@wordpress/i18n';
/**
* Internal dependencies
*/
import Data from 'googlesitekit-data';
import { useSelect, useDispatch } from 'googlesitekit-data';
import { CORE_SITE } from '../../../../../../googlesitekit/datastore/site/constants';
import { MODULES_ANALYTICS_4 } from '../../../../datastore/constants';
import { isInsufficientPermissionsError } from '../../../../../../util/errors';
Expand All @@ -34,8 +34,6 @@ import ReportErrorActions from '../../../../../../components/ReportErrorActions'
import RequestAccessButton from './RequestAccessButton';
import RetryButton from './RetryButton';

const { useSelect, useDispatch } = Data;

export default function ErrorNotice() {
const syncAvailableAudiencesError = useSelect( ( select ) =>
select( MODULES_ANALYTICS_4 ).getErrorForAction(
Expand Down
4 changes: 1 addition & 3 deletions assets/js/modules/analytics-4/datastore/audiences.js
Original file line number Diff line number Diff line change
Expand Up @@ -304,9 +304,7 @@ const baseActions = {
} );

yield commonActions.await(
__experimentalResolveSelect(
MODULES_ANALYTICS_4
).getAudienceSettings()
resolveSelect( MODULES_ANALYTICS_4 ).getAudienceSettings()
);

if ( failedAudiencesToRetry.length > 0 ) {
Expand Down
4 changes: 1 addition & 3 deletions assets/js/modules/reader-revenue-manager/index.js
Original file line number Diff line number Diff line change
Expand Up @@ -57,9 +57,7 @@ export const registerModule = isRrmModuleEnabled( ( modules ) => {
],
checkRequirements: async ( registry ) => {
// Ensure the site info is resolved to get the home URL.
await registry
.__experimentalResolveSelect( CORE_SITE )
.getSiteInfo();
await registry.resolveSelect( CORE_SITE ).getSiteInfo();
const homeURL = registry.select( CORE_SITE ).getHomeURL();

if ( isURLUsingHTTPS( homeURL ) ) {
Expand Down

0 comments on commit 12e537d

Please sign in to comment.