This commit is contained in:
Alexandre Bodin 2019-08-06 08:45:32 +02:00
parent a5e7ca24cc
commit d9e58003f5

View File

@ -890,7 +890,9 @@ const castValueFromType = (type, value) => {
date.setTime(value);
if (!dateFns.isValid(date)) {
throw new Error(`Invalid ${type} format, expected a `);
throw new Error(
`Invalid ${type} format, expected a timestamp or an ISO date`
);
}
return date;