Environment Details

PHP - 5.2.3
Apache - 2.2.3
Drupal - drupal-6.x-dev
OS - Linux (Fedora Core 6)

Steps to reproduce
1 - Enable Forum module

2 - Create a new Forum ("Running")

3 - Access the forum (http://www.testsite8.com/forum/7)
Since there are no forum topics in forum/7 it shows and empty table.

4 - Add a forum topic to forum 7 (http://www.testsite8.com/node/add/forum/7)

5 - Access the forum again (http://www.testsite8.com/forum/7)

it shows a notice
"notice: Undefined property: stdClass::$last_reply in /work/projects/testsites/drupal/6.x/testsite8/www/modules/forum/forum.module on line 769."

see attached screenshot.

CommentFileSizeAuthor
#2 163064_1.patch655 bytesyasheshb
Screenshot-1_5.png99.52 KByasheshb

Comments

steinmb’s picture

I have the same bug:
Clean install of Drupal6 dev 31.7.2007
MySQL: version: 4.1.20
PHP version: 4.3.9

View posting in forum 1: forum/1 and I get:
notice: Undefined property: last_reply in modules/forum/forum.module on line 769.

yasheshb’s picture

Status: Active » Needs review
StatusFileSize
new655 bytes

here's the patch for it.

thx.

yashesh bhatia.

merlinofchaos’s picture

Status: Needs review » Needs work

I think the appropriate fix is around line 563 to make sure $topic->last_reply is actually set to something, even if it's just an empty object. THat's much prettier than having to check.

dvessel’s picture

Status: Needs work » Fixed

Fixed in this patch: http://drupal.org/node/158536

Gurpartap Singh’s picture

Status: Fixed » Closed (duplicate)