Skip to content

Commit

Permalink
Fix console error due to having a RadioGroup.Radio element that has b…
Browse files Browse the repository at this point in the history
…oth the `defaultChecked` and `checked` attributes
  • Loading branch information
wpscholar committed Aug 2, 2023
1 parent 50958ac commit b0b7fba
Showing 1 changed file with 2 additions and 4 deletions.
6 changes: 2 additions & 4 deletions src/app/pages/staging/index.js
Original file line number Diff line number Diff line change
Expand Up @@ -23,8 +23,7 @@ const ProductionSite = ({
title={__('Production site', 'wp-plugin-bluehost')}
description={
<Radio
defaultChecked={isProduction === true ? true : false}
checked={isProduction === true ? true : false}
checked={isProduction === true}
label={isProduction ? __('Currently editing', 'wp-plugin-bluehost') : __('Not currently editing', 'wp-plugin-bluehost') }
id="wppbh-production-toggle"
name="wppbh-staging-selector"
Expand Down Expand Up @@ -77,8 +76,7 @@ const StagingSite = ({
title={__('Staging site', 'wp-plugin-bluehost')}
description={!hasStaging ? __("You don't have a staging site yet.", 'wp-plugin-bluehost') :
<Radio
defaultChecked={isProduction ? false : true}
checked={isProduction ? false : true}
checked={isProduction !== true}
label={isProduction ? __('Not currently editing', 'wp-plugin-bluehost') : __('Currently editing', 'wp-plugin-bluehost') }
id="wppbh-staging-toggle"
name="wppbh-staging-selector"
Expand Down

0 comments on commit b0b7fba

Please sign in to comment.