mirror of
https://github.com/Jermolene/TiddlyWiki5
synced 2025-08-08 06:43:49 +00:00
Improve comments
This commit is contained in:
parent
d0db2221d3
commit
48402ed329
@ -228,7 +228,7 @@ $tw.utils.pad = function(value,length) {
|
|||||||
return s;
|
return s;
|
||||||
};
|
};
|
||||||
|
|
||||||
// Convert a date into YYYYMMDDHHMM format
|
// Convert a date into UTC YYYYMMDDHHMM format
|
||||||
$tw.utils.stringifyDate = function(value) {
|
$tw.utils.stringifyDate = function(value) {
|
||||||
return value.getUTCFullYear() +
|
return value.getUTCFullYear() +
|
||||||
$tw.utils.pad(value.getUTCMonth() + 1) +
|
$tw.utils.pad(value.getUTCMonth() + 1) +
|
||||||
@ -237,7 +237,7 @@ $tw.utils.stringifyDate = function(value) {
|
|||||||
$tw.utils.pad(value.getUTCMinutes());
|
$tw.utils.pad(value.getUTCMinutes());
|
||||||
};
|
};
|
||||||
|
|
||||||
// Parse a date from a YYYYMMDDHHMMSSMMM format string
|
// Parse a date from a UTC YYYYMMDDHHMMSSMMM format string
|
||||||
$tw.utils.parseDate = function(value) {
|
$tw.utils.parseDate = function(value) {
|
||||||
if(typeof value === "string") {
|
if(typeof value === "string") {
|
||||||
return new Date(Date.UTC(parseInt(value.substr(0,4),10),
|
return new Date(Date.UTC(parseInt(value.substr(0,4),10),
|
||||||
|
Loading…
x
Reference in New Issue
Block a user