From 272862d995f44b82c2460314177d36f5b3db9d55 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Erik=20Fr=C3=A8rejean?= Date: Tue, 24 Aug 2010 13:28:57 +0200 Subject: [PATCH] Hopefully fixes http://www.phpbb.com/community/viewtopic.php?f=70&t=2091731&start=210#p12848254 --- root/includes/hooks/hook_subject_prefix.php | 6 ++++++ 1 file changed, 6 insertions(+) diff --git a/root/includes/hooks/hook_subject_prefix.php b/root/includes/hooks/hook_subject_prefix.php index a09ccba..ca28696 100644 --- a/root/includes/hooks/hook_subject_prefix.php +++ b/root/includes/hooks/hook_subject_prefix.php @@ -124,6 +124,12 @@ static private function add_to_index() $last_post_ids[$row] = substr(strrchr($data['U_LAST_POST'], 'p'), 1); } + // Nothing to see here please walk on and mind your own business. + if (empty($last_post_ids)) + { + return; + } + // Get the prefixes $sql = 'SELECT topic_last_post_id, subject_prefix_id FROM ' . TOPICS_TABLE . '