wisest owl (wisest_owl) wrote in changelog,
wisest owl
wisest_owl
changelog

[livejournal] r22852: LJSUP-12558: Read from master instead sl...

Committer: wisest-owl
LJSUP-12558: Read from master instead slave.

U   trunk/cgi-bin/LJ/User/InfoHistory.pm
Modified: trunk/cgi-bin/LJ/User/InfoHistory.pm
===================================================================
--- trunk/cgi-bin/LJ/User/InfoHistory.pm	2012-09-10 13:40:04 UTC (rev 22851)
+++ trunk/cgi-bin/LJ/User/InfoHistory.pm	2012-09-11 08:19:04 UTC (rev 22852)
@@ -27,10 +27,10 @@
 
     $LJ::REQ_GLOBAL{'infohistory_cache'} ||= {};
     unless ( exists $LJ::REQ_GLOBAL{'infohistory_cache'}->{ $u->userid } ) {
-        my $dbr = LJ::get_db_reader();
-        local $dbr->{'RaiseError'} = 1;
+        my $dbh = LJ::get_db_writer();
+        local $dbh->{'RaiseError'} = 1;
 
-        my $rows = $dbr->selectall_arrayref(
+        my $rows = $dbh->selectall_arrayref(
             'SELECT * FROM infohistory WHERE userid=? ORDER BY timechange',
             { 'Slice' => {} },
             $u->userid,

Tags: livejournal, pm, wisest-owl
Subscribe
  • Post a new comment

    Error

    Anonymous comments are disabled in this journal

    default userpic

    Your reply will be screened

    Your IP address will be recorded 

  • 0 comments