Skip to content

Commit

Permalink
rename
Browse files Browse the repository at this point in the history
  • Loading branch information
vraja-pro committed Jan 14, 2025
1 parent e258374 commit c99aad0
Show file tree
Hide file tree
Showing 2 changed files with 3 additions and 3 deletions.
2 changes: 1 addition & 1 deletion packages/js/src/helpers/i18n.js
Original file line number Diff line number Diff line change
Expand Up @@ -35,7 +35,7 @@ export function setTextdomainL10n( textdomain, l10nNamespace = "wpseoYoastJSL10n
* @param {object} conversionMap The conversion map object.
* @returns {string} The interpolated string.
*/
export const i18nCreateInterpolateElement = ( interpolatedString, conversionMap ) => {
export const safeCreateInterpolateElement = ( interpolatedString, conversionMap ) => {
try {
return createInterpolateElement( interpolatedString, conversionMap );
} catch ( error ) {
Expand Down
4 changes: 2 additions & 2 deletions packages/js/src/settings/routes/site-basics.js
Original file line number Diff line number Diff line change
Expand Up @@ -15,7 +15,7 @@ import {
} from "../components";
import { withDisabledMessageSupport, withFormikDummySelectField } from "../hocs";
import { useDispatchSettings, useSelectSettings } from "../hooks";
import { i18nCreateInterpolateElement } from "../../helpers/i18n";
import { safeCreateInterpolateElement } from "../../helpers/i18n";

const ToggleFieldWithDisabledMessageSupport = withDisabledMessageSupport( ToggleField );
const FormikSelectPageWithDummy = withFormikDummySelectField( FormikPageSelectField );
Expand Down Expand Up @@ -105,7 +105,7 @@ const SiteBasics = () => {
strong: <strong className="yst-font-semibold" />,
}
), [] );
const taglineDescription = useMemo( () => i18nCreateInterpolateElement(
const taglineDescription = useMemo( () => safeCreateInterpolateElement(
sprintf(
/**
* translators: %1$s expands to an opening anchor tag.
Expand Down

0 comments on commit c99aad0

Please sign in to comment.