@@ -129,9 +129,11 @@ Validatable.validatesNumericalityOf = getConfigurator('numericality');
129129 * ```
130130 *
131131 * @param {String } propertyName Property name to validate.
132- * @options {Object} Options
132+ * @options {Object} Options See below
133133 * @property {Array } inArray Property must match one of the values in the array to be valid.
134- * @property {String } message Optional error message if property is not valid. Default error message: "is not included in the list".
134+ * @property {String } message Optional error message if property is not valid.
135+ * Default error message: "is not included in the list".
136+ * @property {Boolean } allowNull Whether null values are allowed.
135137 */
136138Validatable . validatesInclusionOf = getConfigurator ( 'inclusion' ) ;
137139
@@ -144,6 +146,7 @@ Validatable.validatesInclusionOf = getConfigurator('inclusion');
144146 * @options {Object} Options
145147 * @property {Array } inArray Property must match one of the values in the array to be valid.
146148 * @property {String } message Optional error message if property is not valid. Default error message: "is reserved".
149+ * @property {Boolean } allowNull Whether null values are allowed.
147150 */
148151Validatable . validatesExclusionOf = getConfigurator ( 'exclusion' ) ;
149152
@@ -157,6 +160,7 @@ Validatable.validatesExclusionOf = getConfigurator('exclusion');
157160 * @options {Object} Options
158161 * @property {RegExp } with Regular expression to validate format.
159162 * @property {String } message Optional error message if property is not valid. Default error message: " is invalid".
163+ * @property {Boolean } allowNull Whether null values are allowed.
160164 */
161165Validatable . validatesFormatOf = getConfigurator ( 'format' ) ;
162166
@@ -178,6 +182,7 @@ Validatable.validatesFormatOf = getConfigurator('format');
178182 * @param {Function } validatorFn Custom validation function.
179183 * @options {Object} Options See below.
180184 * @property {String } message Optional error message if property is not valid. Default error message: " is invalid".
185+ * @property {Boolean } allowNull Whether null values are allowed.
181186 */
182187Validatable . validate = getConfigurator ( 'custom' ) ;
183188
@@ -209,6 +214,7 @@ Validatable.validate = getConfigurator('custom');
209214 * @param {Function } validatorFn Custom validation function.
210215 * @options {Object} Options See below
211216 * @property {String } message Optional error message if property is not valid. Default error message: " is invalid".
217+ * @property {Boolean } allowNull Whether null values are allowed.
212218 */
213219Validatable . validateAsync = getConfigurator ( 'custom' , { async : true } ) ;
214220
@@ -233,6 +239,7 @@ Validatable.validateAsync = getConfigurator('custom', {async: true});
233239 * @property {RegExp } with Regular expression to validate format.
234240 * @property {Array.<String> } scopedTo List of properties defining the scope.
235241 * @property {String } message Optional error message if property is not valid. Default error message: "is not unique".
242+ * @property {Boolean } allowNull Whether null values are allowed.
236243 */
237244Validatable . validatesUniquenessOf = getConfigurator ( 'uniqueness' , { async : true } ) ;
238245
0 commit comments