1
0
mirror of https://github.com/Jermolene/TiddlyWiki5 synced 2024-12-25 01:20:30 +00:00

Add ability to now macro to return same UTC string used in the modified and created fields.

This commit is contained in:
Mark 2017-06-04 19:25:52 -07:00
parent e3544ff3c2
commit 7b6ad7db4a

View File

@ -26,6 +26,9 @@ exports.params = [
Run the macro Run the macro
*/ */
exports.run = function(format) { exports.run = function(format) {
if(format == "UTC") {
return $tw.utils.stringifyDate(new Date());
} else
return $tw.utils.formatDateString(new Date(),format || "0hh:0mm, DDth MMM YYYY"); return $tw.utils.formatDateString(new Date(),format || "0hh:0mm, DDth MMM YYYY");
}; };