FEATURE: Allow single option polls (#8853)

This commit is contained in:
Mark VanLandingham
2020-02-05 08:03:27 -06:00
committed by GitHub
parent 53529a3427
commit 5d97286fa7
7 changed files with 30 additions and 25 deletions

View File

@ -272,9 +272,9 @@ export default Controller.extend({
)
disableInsert(count, isRegular, isMultiple, isNumber, pollMin, pollMax) {
return (
(isRegular && count < 2) ||
(isRegular && count < 1) ||
(isMultiple && count < pollMin && pollMin >= pollMax) ||
(isNumber ? false : count < 2)
(isNumber ? false : count < 1)
);
},