Skip to content

Commit d721665

Browse files
authored
Modify rfc822_datetime to include timezone parameter
Updated rfc822_datetime function to accept timezone.
1 parent e112213 commit d721665

1 file changed

Lines changed: 2 additions & 2 deletions

File tree

libreblog/libreblog.js

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -1442,8 +1442,8 @@ const configTwig = function() {
14421442
return date.replace(" ", "T");
14431443
});
14441444

1445-
globalThis.Twig.extendFunction('rfc822_datetime', (date) => {
1446-
const dateString = date.replace(" ", "T");
1445+
globalThis.Twig.extendFunction('rfc822_datetime', (date, tz) => {
1446+
const dateString = date.replace(" ", "T") + tz;
14471447

14481448
const dayStrings = ["Sun", "Mon", "Tue", "Wed", "Thu", "Fri", "Sat"];
14491449
const monthStrings = ["Jan", "Feb", "Mar", "Apr", "May", "Jun", "Jul", "Aug", "Sep", "Oct", "Nov", "Dec"];

0 commit comments

Comments
 (0)