From: lpsolit%gmail.com <> Date: Wed, 22 Feb 2006 00:33:59 +0000 (+0000) Subject: Bug 315317: DBI placeholders break AppendComment's default timestamp - Patch by Frédé... X-Git-Tag: bugzilla-2.23.1~162 X-Git-Url: http://git.ipfire.org/cgi-bin/gitweb.cgi?a=commitdiff_plain;h=58a9182f1da50a3543a0e781206bc7944c6c124e;p=thirdparty%2Fbugzilla.git Bug 315317: DBI placeholders break AppendComment's default timestamp - Patch by Frédéric Buclin r=mkanat a=justdave --- diff --git a/Bugzilla/Bug.pm b/Bugzilla/Bug.pm index 290c4e7ca8..6165fd2bbe 100755 --- a/Bugzilla/Bug.pm +++ b/Bugzilla/Bug.pm @@ -23,7 +23,7 @@ # Bradley Baetz # Dave Miller # Max Kanat-Alexander -# Frédéric Buclin +# Frédéric Buclin # Lance Larsh package Bugzilla::Bug; @@ -722,7 +722,7 @@ sub AppendComment { # Use the date/time we were given if possible (allowing calling code # to synchronize the comment's timestamp with those of other records). - $timestamp = "NOW()" unless $timestamp; + $timestamp ||= $dbh->selectrow_array('SELECT NOW()'); $comment =~ s/\r\n/\n/g; # Handle Windows-style line endings. $comment =~ s/\r/\n/g; # Handle Mac-style line endings.