0
Fork 0
mirror of https://github.com/TryGhost/Ghost.git synced 2025-02-10 23:36:14 -05:00

Updated error message

refs https://github.com/TryGhost/Team/issues/1811
This commit is contained in:
Djordje Vlaisavljevic 2022-08-17 21:27:02 +02:00
parent 0c49fac5f7
commit 824d03c803

View file

@ -18,13 +18,13 @@ export default BaseValidator.create({
amount(model) {
if (!model.amount) {
if (model.type === 'trial') {
model.errors.add('amount', 'Please enter trial duration of atleast 1 day.');
model.errors.add('amount', 'Free trial must be at least 1 day.');
} else {
model.errors.add('amount', 'Please enter the amount.');
}
this.invalidate();
} else if (model.type === 'trial' && model.amount < 0) {
model.errors.add('amount', 'Please enter trial duration of atleast 1 day.');
model.errors.add('amount', 'Free trial must be at least 1 day.');
this.invalidate();
}
},