@@ -372,7 +372,7 @@ |
||
| 372 | 372 | * |
| 373 | 373 | * @access protected |
| 374 | 374 | * @param mixed $var The variable to test |
| 375 | - * @param mixed $default The default value to use |
|
| 375 | + * @param false|string $default The default value to use |
|
| 376 | 376 | * @return mixed The value of the variable if set, otherwise default value |
| 377 | 377 | */ |
| 378 | 378 | protected function isset_or_default($var, $default) |
@@ -51,7 +51,7 @@ discard block |
||
| 51 | 51 | */ |
| 52 | 52 | public function get_query($topic_id, $topic_title, $length, $sensitivity) |
| 53 | 53 | { |
| 54 | - $ts_query_text = $this->db->sql_escape(str_replace(' ', '|', $topic_title)); |
|
| 54 | + $ts_query_text = $this->db->sql_escape(str_replace(' ', '|', $topic_title)); |
|
| 55 | 55 | |
| 56 | 56 | return array( |
| 57 | 57 | 'SELECT' => "f.forum_id, f.forum_name, t.*, |
@@ -66,7 +66,7 @@ discard block |
||
| 66 | 66 | 'ON' => 'f.forum_id = t.forum_id', |
| 67 | 67 | ), |
| 68 | 68 | ), |
| 69 | - 'WHERE' => "ts_rank_cd(to_tsvector('{$this->ts_name}', t.topic_title), '$ts_query_text', 32) >= " . (float) $sensitivity/10 . ' |
|
| 69 | + 'WHERE' => "ts_rank_cd(to_tsvector('{$this->ts_name}', t.topic_title), '$ts_query_text', 32) >= " . (float) $sensitivity / 10 . ' |
|
| 70 | 70 | AND t.topic_status <> ' . ITEM_MOVED . ' |
| 71 | 71 | AND t.topic_visibility = ' . ITEM_APPROVED . ' |
| 72 | 72 | AND t.topic_time > (extract(epoch from current_timestamp)::integer - ' . (int) $length . ') |