Problem with <lastBuildDate> from Feed plugin?

I was having a problem with the RSS feed on the new Kirby-based site I’m building . In the feed I’m seeing:

: date() expects parameter 2 to be long, string given in
on line

I’ve just checked and the same message is appearing in the feed from the official Kirby blog too.

Am I right in thinking the $modified item in line 8 of the template.php is missing something?

    <lastBuildDate><?php echo date('r', $modified) ?></lastBuildDate>

I’ve just amended the line to:

    <lastBuildDate><?php echo date('r', $site->modified()) ?></lastBuildDate>

I don’t know if this is correct - it certainly produces a correct-looking output but I’m no coder.

The warning message says, that $modifiedwhich is the second parameter in the mentioned date()method gets a string, but needs long (which is kind of integer). So this should also work …

<lastBuildDate><?php echo date('r', (int)$modified) ?></lastBuildDate>

[Edit] I just saw, that there’s an open issue for that:

1 Like

Thank you - I don’t really know my way round Git, but good to hear it’s known-about.