Completed
Push — release-2.1 ( 73c57a...e797f1 )
by Michael
08:24
created
Sources/SearchAPI-Fulltext.php 1 patch
Spacing   +4 added lines, -4 removed lines patch added patch discarded remove patch
@@ -206,7 +206,7 @@  discard block
 block discarded – undo
206 206
 
207 207
 		if (!empty($modSettings['search_simple_fulltext']))
208 208
 		{
209
-			if($smcFunc['db_title'] == "PostgreSQL")
209
+			if ($smcFunc['db_title'] == "PostgreSQL")
210 210
 			{
211 211
 				$language_ftx = $smcFunc['db_search_language']();
212 212
 				
@@ -224,7 +224,7 @@  discard block
 block discarded – undo
224 224
 			// remove any indexed words that are used in the complex body search terms
225 225
 			$words['indexed_words'] = array_diff($words['indexed_words'], $words['complex_words']);
226 226
 
227
-			if($smcFunc['db_title'] == "PostgreSQL"){
227
+			if ($smcFunc['db_title'] == "PostgreSQL") {
228 228
 				$row = 0;
229 229
 				foreach ($words['indexed_words'] as $fulltextWord) {
230 230
 					$query_params['boolean_match'] .= ($row <> 0 ? '&' : '');
@@ -240,7 +240,7 @@  discard block
 block discarded – undo
240 240
 
241 241
 			// if we have bool terms to search, add them in
242 242
 			if ($query_params['boolean_match']) {
243
-				if($smcFunc['db_title'] == "PostgreSQL")
243
+				if ($smcFunc['db_title'] == "PostgreSQL")
244 244
 				{
245 245
 					$language_ftx = $smcFunc['db_search_language']();
246 246
 					
@@ -253,7 +253,7 @@  discard block
 block discarded – undo
253 253
 
254 254
 		}
255 255
 
256
-		$ignoreRequest = $smcFunc['db_search_query']('insert_into_log_messages_fulltext', ($smcFunc['db_support_ignore'] ? ( '
256
+		$ignoreRequest = $smcFunc['db_search_query']('insert_into_log_messages_fulltext', ($smcFunc['db_support_ignore'] ? ('
257 257
 			INSERT IGNORE INTO {db_prefix}' . $search_data['insert_into'] . '
258 258
 				(' . implode(', ', array_keys($query_select)) . ')') : '') . '
259 259
 			SELECT ' . implode(', ', $query_select) . '
Please login to merge, or discard this patch.
Sources/DbSearch-postgresql.php 1 patch
Spacing   +7 added lines, -7 removed lines patch added patch discarded remove patch
@@ -38,12 +38,12 @@  discard block
 block discarded – undo
38 38
 	$version = $smcFunc['db_get_version']();
39 39
 	// if we got a Beta Version
40 40
 	if (stripos($version, 'beta') !== false)
41
-		$version = substr($version, 0, stripos($version, 'beta')).'.0';
41
+		$version = substr($version, 0, stripos($version, 'beta')) . '.0';
42 42
 	// or RC
43 43
 	if (stripos($version, 'rc') !== false)
44
-		$version = substr($version, 0, stripos($version, 'rc')).'.0';
44
+		$version = substr($version, 0, stripos($version, 'rc')) . '.0';
45 45
 
46
-	if (version_compare($version,'9.5.0','>='))
46
+	if (version_compare($version, '9.5.0', '>='))
47 47
 		$smcFunc['db_support_ignore'] = true;
48 48
 }
49 49
 
@@ -55,7 +55,7 @@  discard block
 block discarded – undo
55 55
  */
56 56
 function smf_db_search_support($search_type)
57 57
 {
58
-	$supported_types = array('custom','fulltext');
58
+	$supported_types = array('custom', 'fulltext');
59 59
 
60 60
 	return in_array($search_type, $supported_types);
61 61
 }
@@ -109,9 +109,9 @@  discard block
 block discarded – undo
109 109
 	if (preg_match('~^\s*INSERT\sIGNORE~i', $db_string) != 0)
110 110
 	{
111 111
 		$db_string = preg_replace('~^\s*INSERT\sIGNORE~i', 'INSERT', $db_string);
112
-		if ($smcFunc['db_support_ignore']){
112
+		if ($smcFunc['db_support_ignore']) {
113 113
 			//pg style "INSERT INTO.... ON CONFLICT DO NOTHING"
114
-			$db_string = $db_string.' ON CONFLICT DO NOTHING';
114
+			$db_string = $db_string . ' ON CONFLICT DO NOTHING';
115 115
 		}
116 116
 		else
117 117
 		{
@@ -168,7 +168,7 @@  discard block
 block discarded – undo
168 168
 		$language_ftx = $modSettings['search_language'];
169 169
 	else
170 170
 	{
171
-		$request = $smcFunc['db_query']('','
171
+		$request = $smcFunc['db_query']('', '
172 172
 			SHOW default_text_search_config',
173 173
 			array()
174 174
 		);
Please login to merge, or discard this patch.