Changeset 900


Ignore:
Timestamp:
Dec 9, 2006, 3:25:16 PM (15 years ago)
Author:
sheldon
Message:

Send Last-modified header for feeds to apache in the right format, otherwise it sends incorrect data.

Location:
trunk/lib
Files:
2 edited

Legend:

Unmodified
Added
Removed
  • trunk/lib/OpenGuides.pm

    r898 r900  
    828828    my ($feed_output, $feed_timestamp) =
    829829        $feed->make_feed( %criteria );
    830 
    831     $output .= "Last-Modified: " . $feed_timestamp . "\n\n";
     830    my $maker = $feed->fetch_maker($feed_type);
     831 
     832    $output .= "Last-Modified: " . ($maker->parse_feed_timestamp($feed_timestamp))->strftime('%a, %d %b %Y %H:%M:%S +0000') . "\n\n";
    832833    $output .= $feed_output;
    833834
  • trunk/lib/OpenGuides/Feed.pm

    r891 r900  
    167167    foreach my $node (@nodes) {
    168168        if($node->{last_modified}) {
    169             if((!$newest_node) || ($node->{last_modified} lt $newest_node->{last_modified})) {
     169            if((!$newest_node) || ($node->{last_modified} gt $newest_node->{last_modified})) {
    170170                $newest_node = $node;
    171171            }
Note: See TracChangeset for help on using the changeset viewer.