mark: A photo of Mark kneeling on top of the Taal Volcano in the Philippines. It was a long hike. (Default)
Mark Smith ([staff profile] mark) wrote in [site community profile] changelog2009-10-20 02:50 am

[dw-free] Site-wide search

[commit: http://hg.dwscoalition.org/dw-free/rev/1a7ff043f228]

http://bugs.dwscoalition.org/show_bug.cgi?id=1902

Use logtime, not eventtime, as date_posted. This makes sort-by-date more
reliable.

Patch by [staff profile] mark.

Files modified:
  • bin/worker/sphinx-copier
--------------------------------------------------------------------------------
diff -r b1cb4d76b4b0 -r 1a7ff043f228 bin/worker/sphinx-copier
--- a/bin/worker/sphinx-copier	Tue Oct 20 02:36:10 2009 +0000
+++ b/bin/worker/sphinx-copier	Tue Oct 20 02:49:59 2009 +0000
@@ -105,7 +105,7 @@ sub work {
     # already has most of their posts copied and they are just updating one or two.
     foreach my $jitemid ( @copy_jitemids ) {
         my $row = $dbfrom->selectrow_hashref(
-            q{SELECT l.journalid, l.jitemid, l.posterid, l.security, l.allowmask, l.eventtime, lt.subject, lt.event
+            q{SELECT l.journalid, l.jitemid, l.posterid, l.security, l.allowmask, l.logtime, lt.subject, lt.event
               FROM log2 l INNER JOIN logtext2 lt ON (l.journalid = lt.journalid AND l.jitemid = lt.jitemid)
               WHERE l.journalid = ? AND l.jitemid = ?},
             undef, $u->id, $jitemid
@@ -138,7 +138,7 @@ sub work {
             q{REPLACE INTO posts_raw (id, journal_id, jitemid, poster_id, security_bits, allow_global_search, date_posted,
                                       title, data, revtime)
               VALUES (NULL, ?, ?, ?, ?, ?, UNIX_TIMESTAMP(?), ?, ?, ?)},
-            undef, map { $row->{$_} } qw/ journalid jitemid posterid allowmask allowpublic eventtime subject event edittime /
+            undef, map { $row->{$_} } qw/ journalid jitemid posterid allowmask allowpublic logtime subject event edittime /
         );
         die $dbto->errstr if $dbto->err;
 
--------------------------------------------------------------------------------

Post a comment in response:

This account has disabled anonymous posting.
If you don't have an account you can create one now.
No Subject Icon Selected
More info about formatting

If you are unable to use this captcha for any reason, please contact us by email at support@dreamwidth.org