[livejournal] r20654: LJSUP-10498 (Transfer data from old Scra...
Committer: ailyin
LJSUP-10498 (Transfer data from old Scrapbook to new LJ's photoservice (based on Fotki.com))U trunk/cgi-bin/LJ/User.pm
Modified: trunk/cgi-bin/LJ/User.pm
===================================================================
--- trunk/cgi-bin/LJ/User.pm 2011-11-29 10:40:35 UTC (rev 20653)
+++ trunk/cgi-bin/LJ/User.pm 2011-11-29 12:00:13 UTC (rev 20654)
@@ -7171,6 +7171,7 @@
# 'Q' == Notification Inbox, 'G' == 'SMS messaGe'
# 'D' == 'moDule embed contents', 'W' == 'Wish-list element'
# 'F' == Photo ID, 'A' == Album ID, 'Y' == delaYed entries
+# 'I' == Fotki migration log ID
#
# FIXME: both phonepost and vgift are ljcom. need hooks. but then also
# need a separate namespace. perhaps a separate function/table?
@@ -7181,7 +7182,7 @@
##################################################################
# IF YOU UPDATE THIS MAKE SURE YOU ADD INITIALIZATION CODE BELOW #
- return undef unless $dom =~ /^[LTMPSRKCOVEQGDWFAY]$/; #
+ return undef unless $dom =~ /^[LTMPSRKCOVEQGDWFAYI]$/; #
##################################################################
my $dbh = LJ::get_db_writer();
@@ -7308,6 +7309,9 @@
} elsif ($dom eq "Y") {
$newmax = $u->selectrow_array("SELECT MAX(delayedid) FROM delayedlog2 WHERE journalid=?",
undef, $uid);
+ } elsif ( $dom eq 'I' ) {
+ $newmax = $u->selectrow_array("SELECT MAX(logid) FROM fotki_migrate_log WHERE userid=?",
+ undef, $uid);
} else {
die "No user counter initializer defined for area '$dom'.\n";
}
