"Fossies" - the Fresh Open Source Software Archive  

Source code changes of the file "min/moment-with-locales.js" between
moment-2.29.3.tar.gz and moment-2.29.4.tar.gz

About: Moment.js is a JavaScript date library for parsing, validating, manipulating, and formatting dates.

moment-with-locales.js  (moment-2.29.3):moment-with-locales.js  (moment-2.29.4)
skipping to change at line 2451 skipping to change at line 2451
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 wi th a single space // Remove comments and folding whitespace and replace multiple-spaces wi th 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-week check. // TODO: Replace the vanilla JS Date object with an independent day- of-week check.
var weekdayProvided = defaultLocaleWeekdaysShort.indexOf(weekdayStr) , var weekdayProvided = defaultLocaleWeekdaysShort.indexOf(weekdayStr) ,
weekdayActual = new Date( weekdayActual = new Date(
skipping to change at line 5632 skipping to change at line 5632
addRegexToken('X', matchTimestamp); addRegexToken('X', matchTimestamp);
addParseToken('X', function (input, array, config) { addParseToken('X', function (input, array, config) {
config._d = new Date(parseFloat(input) * 1000); config._d = new Date(parseFloat(input) * 1000);
}); });
addParseToken('x', function (input, array, config) { addParseToken('x', function (input, array, config) {
config._d = new Date(toInt(input)); config._d = new Date(toInt(input));
}); });
//! moment.js //! moment.js
hooks.version = '2.29.3'; hooks.version = '2.29.4';
setHookCallback(createLocal); setHookCallback(createLocal);
hooks.fn = proto; hooks.fn = proto;
hooks.min = min; hooks.min = min;
hooks.max = max; hooks.max = max;
hooks.now = now; hooks.now = now;
hooks.utc = createUTC; hooks.utc = createUTC;
hooks.unix = createUnix; hooks.unix = createUnix;
hooks.months = listMonths; hooks.months = listMonths;
 End of changes. 2 change blocks. 
2 lines changed or deleted 2 lines changed or added

Home  |  About  |  Features  |  All  |  Newest  |  Dox  |  Diffs  |  RSS Feeds  |  Screenshots  |  Comments  |  Imprint  |  Privacy  |  HTTP(S)