Skip to content

Commit

Permalink
removed default url
Browse files Browse the repository at this point in the history
  • Loading branch information
ajayadav09 committed Apr 30, 2024
1 parent f19c93f commit 97c1468
Show file tree
Hide file tree
Showing 2 changed files with 3 additions and 5 deletions.
3 changes: 1 addition & 2 deletions src/OnboardingSPA/components/MiniPreview/contents.js
Original file line number Diff line number Diff line change
Expand Up @@ -2,7 +2,7 @@ import { __, sprintf } from '@wordpress/i18n';

import { translations } from '../../utils/locales/translations';

const getContents = ( brandUrl = '' ) => {
const getContents = () => {
return {
heading: __( 'Preview', 'wp-module-onboarding' ),
defaultTitle: sprintf(
Expand All @@ -15,7 +15,6 @@ const getContents = ( brandUrl = '' ) => {
__( 'Just another WordPress %s', 'wp-module-onboarding' ),
translations( 'Site' )
),
defaultUrl: brandUrl,
};
};

Expand Down
5 changes: 2 additions & 3 deletions src/OnboardingSPA/components/MiniPreview/index.js
Original file line number Diff line number Diff line change
Expand Up @@ -13,15 +13,14 @@ const MiniPreview = ( {
isSocialFormOpen,
setIsSocialFormOpen,
} ) => {
const { socialDataStore, brandUrl } = useSelect( ( select ) => {
const { socialDataStore } = useSelect( ( select ) => {
return {
socialDataStore:
select( nfdOnboardingStore ).getOnboardingSocialData(),
brandUrl: select( nfdOnboardingStore ).getNewfoldBrandUrl(),
};
}, [] );

const content = getContents( brandUrl );
const content = getContents();
const titlePreview = title === '' ? content.defaultTitle : title;
const descPreview = desc === '' ? content.defaultDesc : desc;

Expand Down

0 comments on commit 97c1468

Please sign in to comment.