mirror of
https://github.com/TryGhost/Ghost.git
synced 2025-02-03 23:00:14 -05:00
Fixed default recipients behaviour when deselecting all tiers (#17133)
refs https://github.com/TryGhost/Team/issues/3349
This commit is contained in:
parent
d9785b7d6b
commit
fdef6a30ab
1 changed files with 7 additions and 2 deletions
|
@ -150,8 +150,13 @@ const DefaultRecipients: React.FC = () => {
|
|||
.filter(({value}) => filters.includes(value));
|
||||
|
||||
const setSelectedSegments = (selected: MultiValue<MultiSelectOption>) => {
|
||||
const selectedGroups = selected?.map(({value}) => value).join(',');
|
||||
updateSetting('editor_default_email_recipients_filter', selectedGroups);
|
||||
if (selected.length) {
|
||||
const selectedGroups = selected?.map(({value}) => value).join(',');
|
||||
updateSetting('editor_default_email_recipients_filter', selectedGroups);
|
||||
} else {
|
||||
updateSetting('editor_default_email_recipients_filter', null);
|
||||
setSelectedOption('none');
|
||||
}
|
||||
};
|
||||
|
||||
const values = (
|
||||
|
|
Loading…
Add table
Reference in a new issue