diff --git a/packages/jv-input-controls/src/utils/DateInputControlUtils.ts b/packages/jv-input-controls/src/utils/DateInputControlUtils.ts index d214b422..f1c8fdde 100644 --- a/packages/jv-input-controls/src/utils/DateInputControlUtils.ts +++ b/packages/jv-input-controls/src/utils/DateInputControlUtils.ts @@ -138,13 +138,17 @@ export const verifyDateLimit = ({ isVerifyingMin, }: { dataType: InputControlDataType | undefined; - maxOrMinDateAsString: string | null; + maxOrMinDateAsString: string | null | undefined; dateAsString: string; isVerifyingMin: boolean; }): { helperText: string; isError: boolean } => { let helperText = ""; let isError = false; - if (dataType === undefined || maxOrMinDateAsString === null) { + if ( + dataType === undefined || + maxOrMinDateAsString === null || + maxOrMinDateAsString === undefined + ) { return { helperText, isError }; } // verify the number is under the limits of the data type