Changeset 1902

Show
Ignore:
Timestamp:
04/15/08 01:42:41 (4 months ago)
Author:
fumiakiy
Message:

Restore userpic association. BugId:75025

Files:

Legend:

Unmodified
Added
Removed
Modified
Copied
Moved
  • branches/release-35/lib/MT/BackupRestore.pm

    r1823 r1902  
    469469                old_id => $old_id, 
    470470            }; 
     471        } elsif ( $key =~ /^MT::Author#(\d+)$/ ) { 
     472            # restore userpic association now 
     473            my $new_author = $all_objects->{$key}; 
     474            if ( my $userpic_id = $new_author->userpic_asset_id ) { 
     475                if ( my $new_asset = $all_objects->{'MT::Asset#' . $userpic_id} ) { 
     476                    $new_author->userpic_asset_id( $new_asset->id ); 
     477                    $new_author->update; 
     478                } 
     479            } 
    471480        } 
    472481    } 
  • branches/release-35/lib/MT/CMS/Tools.pm

    r1823 r1902  
    22 
    33use strict; 
     4use Symbol; 
    45 
    56use MT::I18N qw( encode_text );