Changeset 688

Show
Ignore:
Timestamp:
05/05/06 20:16:32
Author:
miyagawa
Message:

oops, this was unintentional

Files:

Legend:

Unmodified
Added
Removed
Modified
Copied
Moved
  • trunk/plagger/lib/Plagger/Date.pm

    r687 r688  
    77use UNIVERSAL::require; 
    88 
    9 sub rebless { 
    10     my($class, $dt) = @_; 
    11     bless $dt, $class; 
    12 
     9sub rebless { bless $_[1], $_[0] } 
    1310 
    1411sub parse { 
     
    2421 
    2522    my $dt = $module->parse_datetime($date) or return; 
    26     $class->rebless($dt); 
     23 
     24    # If parsed datetime is floating, don't set timezone here. It should be "fixed" in caller plugins 
     25    unless ($dt->time_zone->is_floating) { 
     26        $dt->set_time_zone( Plagger->context->conf->{timezone} || 'local' ); 
     27    } 
     28 
     29    bless $dt, $class; 
    2730} 
    2831