1
0
Fork 0
forked from 0x2620/oxjs

fix semicolons

This commit is contained in:
rolux 2014-08-19 10:19:59 +02:00
commit 1b90cc6ac8
12 changed files with 38 additions and 38 deletions

View file

@ -29,7 +29,7 @@ Ox.getDateInWeek = function(date, weekday, utc) {
return v.slice(0, 3) == weekday.slice(0, 3);
}) + 1;
return Ox.setDate(date, Ox.getDate(date, utc) - sourceWeekday + targetWeekday, utc);
}
};
//@ Ox.getDay <f> Get the weekday of a date, optionally UTC
// see Ox.setSeconds for source code
@ -76,7 +76,7 @@ Ox.getDaysInMonth = function(year, month) {
}) + 1;
// Set to 1 AM since we may hit a DST change
return new Date(year, month, 0, 1).getDate();
}
};
/*@
Ox.getDaysInYear <f> Get the number of days in a given year
@ -101,7 +101,7 @@ Ox.getFirstDayOfTheYear = function(date, utc) {
date = Ox.makeDate(date);
date = Ox.setMonth(date, 0, utc);
date = Ox.setDate(date, 1, utc);
return Ox.getDay(date, utc)
return Ox.getDay(date, utc);
};
//@ Ox.getFullYear <f> Get the year of a date, optionally UTC
@ -356,11 +356,11 @@ Ox.parseDateRange = function(start, end, utc) {
].forEach(function(part) {
Ox['get' + part] = function(date, utc) {
return Ox.makeDate(date)['get' + (utc ? 'UTC' : '') + part]();
}
};
// Ox.setPart(date) modifies date
Ox['set' + part] = function(date, num, utc) {
return (
Ox.isDate(date) ? date : new Date(date)
)['set' + (utc ? 'UTC' : '') + part](num);
}
};
});