tie p2p action only to targetted date-summary entry if there are multiple (#367)

This commit is contained in:
Ben Warzeski
2021-02-22 13:48:43 -05:00
committed by GitHub
parent 4bbc29591c
commit 26a7b3b0de

View File

@@ -15,7 +15,10 @@ export default function DateSummary({
/** [MM-P2P experiment] */
const [showMMP2P, setShowMMP2P] = useState(window.experiment__home_dates_bShowMMP2P);
if (window.experiment__home_dates_showMMP2P === undefined) {
if (
dateBlock.dateType === 'verified-upgrade-deadline'
&& window.experiment__home_dates_showMMP2P === undefined
) {
window.experiment__home_dates_showMMP2P = (value) => {
setShowMMP2P(!!value);
window.experiment__home_dates_bShowMMP2P = !!value;