from-string.js (moment-2.29.3) | : | from-string.js (moment-2.29.4) | ||
---|---|---|---|---|
skipping to change at line 154 | skipping to change at line 154 | |||
return 2000 + year; | return 2000 + year; | |||
} else if (year <= 999) { | } else if (year <= 999) { | |||
return 1900 + year; | return 1900 + year; | |||
} | } | |||
return year; | return year; | |||
} | } | |||
function preprocessRFC2822(s) { | function preprocessRFC2822(s) { | |||
// Remove comments and folding whitespace and replace multiple-spaces with a single space | // Remove comments and folding whitespace and replace multiple-spaces with a single space | |||
return s | return s | |||
.replace(/\([^)]*\)|[\n\t]/g, ' ') | .replace(/\([^()]*\)|[\n\t]/g, ' ') | |||
.replace(/(\s\s+)/g, ' ') | .replace(/(\s\s+)/g, ' ') | |||
.replace(/^\s\s*/, '') | .replace(/^\s\s*/, '') | |||
.replace(/\s\s*$/, ''); | .replace(/\s\s*$/, ''); | |||
} | } | |||
function checkWeekday(weekdayStr, parsedInput, config) { | function checkWeekday(weekdayStr, parsedInput, config) { | |||
if (weekdayStr) { | if (weekdayStr) { | |||
// TODO: Replace the vanilla JS Date object with an independent day-of-w eek check. | // TODO: Replace the vanilla JS Date object with an independent day-of-w eek check. | |||
var weekdayProvided = defaultLocaleWeekdaysShort.indexOf(weekdayStr), | var weekdayProvided = defaultLocaleWeekdaysShort.indexOf(weekdayStr), | |||
weekdayActual = new Date( | weekdayActual = new Date( | |||
End of changes. 1 change blocks. | ||||
1 lines changed or deleted | 1 lines changed or added |