Passed
Pull Request — master (#340)
by
unknown
02:44
created
core/controller/search.php 1 patch
Spacing   +12 added lines, -12 removed lines patch added patch discarded remove patch
@@ -141,10 +141,10 @@  discard block
 block discarded – undo
141 141
 
142 142
 	public function base($page = 1)
143 143
 	{
144
-		$search_id		= $this->request->variable('search_id', '');
144
+		$search_id = $this->request->variable('search_id', '');
145 145
 		$image_id		= $this->request->variable('image_id', 0);
146 146
 
147
-		$submit			= $this->request->variable('submit', false);
147
+		$submit = $this->request->variable('submit', false);
148 148
 		$keywords		= utf8_normalize_nfc($this->request->variable('keywords', '', true));
149 149
 		$add_keywords	= utf8_normalize_nfc($this->request->variable('add_keywords', '', true));
150 150
 		$username		= $this->request->variable('username', '', true);
@@ -152,13 +152,13 @@  discard block
 block discarded – undo
152 152
 		$search_terms	= $this->request->variable('terms', 'all');
153 153
 		$search_album	= $this->request->variable('aid', array(0));
154 154
 		$search_child	= $this->request->variable('sc', true);
155
-		$search_fields	= $this->request->variable('sf', 'all');
156
-		$sort_days		= $this->request->variable('st', 0);
155
+		$search_fields = $this->request->variable('sf', 'all');
156
+		$sort_days = $this->request->variable('st', 0);
157 157
 		$sort_key		= $this->request->variable('sk', 't');
158 158
 		$sort_dir		= $this->request->variable('sd', 'd');
159 159
 		$filtered		= $this->request->variable('filtered', false);
160 160
 
161
-		$start 			= ($page - 1) * $this->gallery_config->get('items_per_page');
161
+		$start = ($page - 1) * $this->gallery_config->get('items_per_page');
162 162
 		if ($filtered)
163 163
 		{
164 164
 			$submit = true;
@@ -175,7 +175,7 @@  discard block
 block discarded – undo
175 175
 		if ($this->gallery_config->get('allow_rates'))
176 176
 		{
177 177
 			$sort_by_text['ra'] = $this->language->lang('RATING');
178
-			$sort_by_sql['ra'] = 'image_rate_points';//@todo: (phpbb_gallery_contest::$mode == phpbb_gallery_contest::MODE_SUM) ? 'image_rate_points' : 'image_rate_avg';
178
+			$sort_by_sql['ra'] = 'image_rate_points'; //@todo: (phpbb_gallery_contest::$mode == phpbb_gallery_contest::MODE_SUM) ? 'image_rate_points' : 'image_rate_avg';
179 179
 			$sort_by_text['r'] = $this->language->lang('RATES_COUNT');
180 180
 			$sort_by_sql['r'] = 'image_rates';
181 181
 		}
@@ -206,7 +206,7 @@  discard block
 block discarded – undo
206 206
 				{
207 207
 					trigger_error(sprintf($this->language->lang('TOO_FEW_AUTHOR_CHARS'), $this->config['min_search_author_chars']));
208 208
 				}
209
-				$username_parsed = (strpos($username, '*') !== false) ? ' username_clean ' . $this->db->sql_like_expression(str_replace('*', $this->db->get_any_char(), utf8_clean_string($this->db->sql_escape($username)))) : ' username_clean = \'' . $this->db->sql_escape(utf8_clean_string($username)) .'\'';
209
+				$username_parsed = (strpos($username, '*') !== false) ? ' username_clean ' . $this->db->sql_like_expression(str_replace('*', $this->db->get_any_char(), utf8_clean_string($this->db->sql_escape($username)))) : ' username_clean = \'' . $this->db->sql_escape(utf8_clean_string($username)) . '\'';
210 210
 				$sql = 'SELECT user_id
211 211
 					FROM ' . USERS_TABLE . '
212 212
 					WHERE ' . $username_parsed . '
@@ -224,7 +224,7 @@  discard block
 block discarded – undo
224 224
 
225 225
 			if (!empty($user_id))
226 226
 			{
227
-				$sql_where[] =  $this->db->sql_in_set('i.image_user_id', $user_id);
227
+				$sql_where[] = $this->db->sql_in_set('i.image_user_id', $user_id);
228 228
 			}
229 229
 			// if we search in an existing search result just add the additional keywords. But we need to use "all search terms"-mode
230 230
 			// so we can keep the old keywords in their old mode, but add the new ones as required words
@@ -237,7 +237,7 @@  discard block
 block discarded – undo
237 237
 				else
238 238
 				{
239 239
 					$search_terms = 'all';
240
-					$keywords = preg_replace('#\s+#u', ' |', $keywords) . ' ' .$add_keywords;
240
+					$keywords = preg_replace('#\s+#u', ' |', $keywords) . ' ' . $add_keywords;
241 241
 				}
242 242
 			}
243 243
 			$keywords_ary = ($keywords) ? explode(' ', $keywords) : array();
@@ -262,7 +262,7 @@  discard block
 block discarded – undo
262 262
 				$match_search_query = '';
263 263
 				foreach ($matches as $match)
264 264
 				{
265
-					$match_search_query .= (($match_search_query) ? ' OR ' : '') . 'LOWER('. $match . ') ';
265
+					$match_search_query .= (($match_search_query) ? ' OR ' : '') . 'LOWER(' . $match . ') ';
266 266
 					$match_search_query .= $this->db->sql_like_expression(str_replace('*', $this->db->get_any_char(), $this->db->get_any_char() . mb_strtolower($word) . $this->db->get_any_char()));
267 267
 				}
268 268
 				$search_query .= ((!$search_query) ? '' : (($search_terms == 'all') ? ' AND ' : ' OR ')) . '(' . $match_search_query . ')';
@@ -291,7 +291,7 @@  discard block
 block discarded – undo
291 291
 				trigger_error('NO_SEARCH_RESULTS');
292 292
 			}
293 293
 			$sql_array['SELECT'] = '*, a.album_name, a.album_status, a.album_user_id, a.album_id';
294
-			$sql_array['LEFT_JOIN']	= array(
294
+			$sql_array['LEFT_JOIN'] = array(
295 295
 				array(
296 296
 					'FROM'		=> array($this->albums_table => 'a'),
297 297
 					'ON'		=> 'a.album_id = i.image_album_id',
@@ -319,7 +319,7 @@  discard block
 block discarded – undo
319 319
 			{
320 320
 				$this->image->assign_block('imageblock.image', $row, $show_options, $thumbnail_link, $imagename_link);
321 321
 			}
322
-			$current_page = $page*$this->gallery_config->get('items_per_page');
322
+			$current_page = $page * $this->gallery_config->get('items_per_page');
323 323
 			$this->pagination->generate_template_pagination(array(
324 324
 				'routes' => array(
325 325
 					'phpbbgallery_core_search',
Please login to merge, or discard this patch.
exif/language/it/info_exif.php 1 patch
Spacing   +3 added lines, -3 removed lines patch added patch discarded remove patch
@@ -30,9 +30,9 @@  discard block
 block discarded – undo
30 30
 	'EXIF_CAM_MODEL'			=> 'Modello Camera',
31 31
 	'EXIF_DATE'					=> 'Immagine scattata il',
32 32
 	'EXIF_EXPOSURE'				=> 'Velocita\' otturatore',
33
-	'EXIF_EXPOSURE_EXP'			=> '%s Sec',// 'EXIF_EXPOSURE' unit
33
+	'EXIF_EXPOSURE_EXP'			=> '%s Sec', // 'EXIF_EXPOSURE' unit
34 34
 	'EXIF_EXPOSURE_BIAS'		=> 'Inclinazione di esposizione',
35
-	'EXIF_EXPOSURE_BIAS_EXP'	=> '%s EV',// 'EXIF_EXPOSURE_BIAS' unit
35
+	'EXIF_EXPOSURE_BIAS_EXP'	=> '%s EV', // 'EXIF_EXPOSURE_BIAS' unit
36 36
 	'EXIF_EXPOSURE_PROG'		=> 'Programma di esposizione',
37 37
 	'EXIF_EXPOSURE_PROG_0'		=> 'Non definito',
38 38
 	'EXIF_EXPOSURE_PROG_1'		=> 'Manuale',
@@ -72,7 +72,7 @@  discard block
 block discarded – undo
72 72
 	'EXIF_FLASH_CASE_93'		=> 'Il flash e\' scattato, modalita\' automatica, luce di ritorno non rilevata, modalita\' riduzione occhi rossi',
73 73
 	'EXIF_FLASH_CASE_95'		=> 'Il flash e\' scattato, modalita\' automatica, luce di ritorno rilevata, modalita\' riduzione occhi rossi',
74 74
 	'EXIF_FOCAL'				=> 'Lunghezza di Focus',
75
-	'EXIF_FOCAL_EXP'			=> '%s mm',// 'EXIF_FOCAL' unit
75
+	'EXIF_FOCAL_EXP'			=> '%s mm', // 'EXIF_FOCAL' unit
76 76
 	'EXIF_ISO'					=> 'Valore di velocita\' ISO',
77 77
 	'EXIF_METERING_MODE'		=> 'Modalita\' di metratura',
78 78
 	'EXIF_METERING_MODE_0'		=> 'Sconosciuta',
Please login to merge, or discard this patch.
exif/event/exif_listener.php 1 patch
Spacing   +2 added lines, -2 removed lines patch added patch discarded remove patch
@@ -70,7 +70,7 @@  discard block
 block discarded – undo
70 70
 		$this->user = $user;
71 71
 		$this->gallery_config = $gallery_config;
72 72
 		$this->gallery_auth = $gallery_auth;
73
-		$this->gallery_url	= $gallery_url;
73
+		$this->gallery_url = $gallery_url;
74 74
 		$this->gallery_user = $gallery_user;
75 75
 	}
76 76
 
@@ -83,7 +83,7 @@  discard block
 block discarded – undo
83 83
 			{
84 84
 				$this->user->add_lang_ext('phpbbgallery/exif', 'info_exif');
85 85
 
86
-				$return_ary['vars']['IMAGE_SETTINGS']['disp_exifdata'] = array('lang' => 'DISP_EXIF_DATA',		'validate' => 'bool',	'type' => 'radio:yes_no');
86
+				$return_ary['vars']['IMAGE_SETTINGS']['disp_exifdata'] = array('lang' => 'DISP_EXIF_DATA', 'validate' => 'bool', 'type' => 'radio:yes_no');
87 87
 				$event['return_ary'] = $return_ary;
88 88
 			}
89 89
 		}
Please login to merge, or discard this patch.
exif/language/bg/info_exif.php 1 patch
Spacing   +3 added lines, -3 removed lines patch added patch discarded remove patch
@@ -30,9 +30,9 @@  discard block
 block discarded – undo
30 30
 	'EXIF_CAM_MODEL'			=> 'Camera-model',
31 31
 	'EXIF_DATE'					=> 'Image taken on',
32 32
 	'EXIF_EXPOSURE'				=> 'Shutter speed',
33
-	'EXIF_EXPOSURE_EXP'			=> '%s Sec',// 'EXIF_EXPOSURE' unit
33
+	'EXIF_EXPOSURE_EXP'			=> '%s Sec', // 'EXIF_EXPOSURE' unit
34 34
 	'EXIF_EXPOSURE_BIAS'		=> 'Exposure bias',
35
-	'EXIF_EXPOSURE_BIAS_EXP'	=> '%s EV',// 'EXIF_EXPOSURE_BIAS' unit
35
+	'EXIF_EXPOSURE_BIAS_EXP'	=> '%s EV', // 'EXIF_EXPOSURE_BIAS' unit
36 36
 	'EXIF_EXPOSURE_PROG'		=> 'Exposure program',
37 37
 	'EXIF_EXPOSURE_PROG_0'		=> 'Not defined',
38 38
 	'EXIF_EXPOSURE_PROG_1'		=> 'Manual',
@@ -72,7 +72,7 @@  discard block
 block discarded – undo
72 72
 	'EXIF_FLASH_CASE_93'		=> 'Flash fired, auto mode, return light not detected, red-eye reduction mode',
73 73
 	'EXIF_FLASH_CASE_95'		=> 'Flash fired, auto mode, return light detected, red-eye reduction mode',
74 74
 	'EXIF_FOCAL'				=> 'Focus length',
75
-	'EXIF_FOCAL_EXP'			=> '%s mm',// 'EXIF_FOCAL' unit
75
+	'EXIF_FOCAL_EXP'			=> '%s mm', // 'EXIF_FOCAL' unit
76 76
 	'EXIF_ISO'					=> 'ISO speed rating',
77 77
 	'EXIF_METERING_MODE'		=> 'Metering mode',
78 78
 	'EXIF_METERING_MODE_0'		=> 'Unknown',
Please login to merge, or discard this patch.
exif/language/en/info_exif.php 1 patch
Spacing   +3 added lines, -3 removed lines patch added patch discarded remove patch
@@ -30,9 +30,9 @@  discard block
 block discarded – undo
30 30
 	'EXIF_CAM_MODEL'			=> 'Camera-model',
31 31
 	'EXIF_DATE'					=> 'Image taken on',
32 32
 	'EXIF_EXPOSURE'				=> 'Shutter speed',
33
-	'EXIF_EXPOSURE_EXP'			=> '%s Sec',// 'EXIF_EXPOSURE' unit
33
+	'EXIF_EXPOSURE_EXP'			=> '%s Sec', // 'EXIF_EXPOSURE' unit
34 34
 	'EXIF_EXPOSURE_BIAS'		=> 'Exposure bias',
35
-	'EXIF_EXPOSURE_BIAS_EXP'	=> '%s EV',// 'EXIF_EXPOSURE_BIAS' unit
35
+	'EXIF_EXPOSURE_BIAS_EXP'	=> '%s EV', // 'EXIF_EXPOSURE_BIAS' unit
36 36
 	'EXIF_EXPOSURE_PROG'		=> 'Exposure program',
37 37
 	'EXIF_EXPOSURE_PROG_0'		=> 'Not defined',
38 38
 	'EXIF_EXPOSURE_PROG_1'		=> 'Manual',
@@ -72,7 +72,7 @@  discard block
 block discarded – undo
72 72
 	'EXIF_FLASH_CASE_93'		=> 'Flash fired, auto mode, return light not detected, red-eye reduction mode',
73 73
 	'EXIF_FLASH_CASE_95'		=> 'Flash fired, auto mode, return light detected, red-eye reduction mode',
74 74
 	'EXIF_FOCAL'				=> 'Focus length',
75
-	'EXIF_FOCAL_EXP'			=> '%s mm',// 'EXIF_FOCAL' unit
75
+	'EXIF_FOCAL_EXP'			=> '%s mm', // 'EXIF_FOCAL' unit
76 76
 	'EXIF_ISO'					=> 'ISO speed rating',
77 77
 	'EXIF_METERING_MODE'		=> 'Metering mode',
78 78
 	'EXIF_METERING_MODE_0'		=> 'Unknown',
Please login to merge, or discard this patch.
exif/language/fr/info_exif.php 1 patch
Spacing   +3 added lines, -3 removed lines patch added patch discarded remove patch
@@ -31,9 +31,9 @@  discard block
 block discarded – undo
31 31
 	'EXIF_CAM_MODEL'			=> 'Modèle d’appareil photo',
32 32
 	'EXIF_DATE'					=> 'Image prise le',
33 33
 	'EXIF_EXPOSURE'				=> 'Vitesse d’obturation',
34
-	'EXIF_EXPOSURE_EXP'			=> '%s Sec',// 'EXIF_EXPOSURE' unit
34
+	'EXIF_EXPOSURE_EXP'			=> '%s Sec', // 'EXIF_EXPOSURE' unit
35 35
 	'EXIF_EXPOSURE_BIAS'		=> 'Angle d’exposition',
36
-	'EXIF_EXPOSURE_BIAS_EXP'	=> '%s EV',// 'EXIF_EXPOSURE_BIAS' unit
36
+	'EXIF_EXPOSURE_BIAS_EXP'	=> '%s EV', // 'EXIF_EXPOSURE_BIAS' unit
37 37
 	'EXIF_EXPOSURE_PROG'		=> 'Programme d’exposition',
38 38
 	'EXIF_EXPOSURE_PROG_0'		=> 'Non défini',
39 39
 	'EXIF_EXPOSURE_PROG_1'		=> 'Manuel',
@@ -73,7 +73,7 @@  discard block
 block discarded – undo
73 73
 	'EXIF_FLASH_CASE_93'		=> 'Flash déclenché, mode automatique, avec retour de lumière non détecté, yeux rouges réduits',
74 74
 	'EXIF_FLASH_CASE_95'		=> 'Flash déclenché, mode automatique, avec retour de lumière détecté, yeux rouges réduits',
75 75
 	'EXIF_FOCAL'				=> 'Longueur de focale',
76
-	'EXIF_FOCAL_EXP'			=> '%s mm',// 'EXIF_FOCAL' unit
76
+	'EXIF_FOCAL_EXP'			=> '%s mm', // 'EXIF_FOCAL' unit
77 77
 	'EXIF_ISO'					=> 'Sensibilité ISO',
78 78
 	'EXIF_METERING_MODE'		=> 'Mode de mesure',
79 79
 	'EXIF_METERING_MODE_0'		=> 'Inconnu',
Please login to merge, or discard this patch.
exif/language/ru/info_exif.php 1 patch
Spacing   +3 added lines, -3 removed lines patch added patch discarded remove patch
@@ -31,9 +31,9 @@  discard block
 block discarded – undo
31 31
 	'EXIF_CAM_MODEL'			=> 'Модель камеры',
32 32
 	'EXIF_DATE'					=> 'Изображение заснято',
33 33
 	'EXIF_EXPOSURE'				=> 'Выдержка',
34
-	'EXIF_EXPOSURE_EXP'			=> '%s сек',// 'EXIF_EXPOSURE' unit
34
+	'EXIF_EXPOSURE_EXP'			=> '%s сек', // 'EXIF_EXPOSURE' unit
35 35
 	'EXIF_EXPOSURE_BIAS'		=> 'Корректировка выдержки',
36
-	'EXIF_EXPOSURE_BIAS_EXP'	=> '%s LW',// 'EXIF_EXPOSURE_BIAS' unit
36
+	'EXIF_EXPOSURE_BIAS_EXP'	=> '%s LW', // 'EXIF_EXPOSURE_BIAS' unit
37 37
 	'EXIF_EXPOSURE_PROG'		=> 'Программа экспозиции',
38 38
 	'EXIF_EXPOSURE_PROG_0'		=> 'Неопределенно',
39 39
 	'EXIF_EXPOSURE_PROG_1'		=> 'Вручную',
@@ -73,7 +73,7 @@  discard block
 block discarded – undo
73 73
 	'EXIF_FLASH_CASE_93'		=> 'Вспышка сработала, авторежим, нет отражателя вспышки, подавление эффекта красных глаз',
74 74
 	'EXIF_FLASH_CASE_95'		=> 'Вспышка сработала, авторежим, отражатель вспышки сработал, подавление эффекта красных глаз',
75 75
 	'EXIF_FOCAL'				=> 'Фокусное расстояние',
76
-	'EXIF_FOCAL_EXP'			=> '%s mm',// 'EXIF_FOCAL' unit
76
+	'EXIF_FOCAL_EXP'			=> '%s mm', // 'EXIF_FOCAL' unit
77 77
 	'EXIF_ISO'					=> 'ISO-чувствительность',
78 78
 	'EXIF_METERING_MODE'		=> 'Метод выдержки и измерения',
79 79
 	'EXIF_METERING_MODE_0'		=> 'Неизвестно',
Please login to merge, or discard this patch.
exif/language/de/info_exif.php 1 patch
Spacing   +3 added lines, -3 removed lines patch added patch discarded remove patch
@@ -31,9 +31,9 @@  discard block
 block discarded – undo
31 31
 	'EXIF_CAM_MODEL'			=> 'Kamera-Modell',
32 32
 	'EXIF_DATE'					=> 'Bild aufgenommen am',
33 33
 	'EXIF_EXPOSURE'				=> 'Belichtungszeit',
34
-	'EXIF_EXPOSURE_EXP'			=> '%s Sek',// 'EXIF_EXPOSURE' unit
34
+	'EXIF_EXPOSURE_EXP'			=> '%s Sek', // 'EXIF_EXPOSURE' unit
35 35
 	'EXIF_EXPOSURE_BIAS'		=> 'Belichtungskorrektur',
36
-	'EXIF_EXPOSURE_BIAS_EXP'	=> '%s LW',// 'EXIF_EXPOSURE_BIAS' unit
36
+	'EXIF_EXPOSURE_BIAS_EXP'	=> '%s LW', // 'EXIF_EXPOSURE_BIAS' unit
37 37
 	'EXIF_EXPOSURE_PROG'		=> 'Belichtungsprogramm',
38 38
 	'EXIF_EXPOSURE_PROG_0'		=> 'Nicht definiert',
39 39
 	'EXIF_EXPOSURE_PROG_1'		=> 'Manuell',
@@ -73,7 +73,7 @@  discard block
 block discarded – undo
73 73
 	'EXIF_FLASH_CASE_93'		=> 'Blitz wurde ausgelöst, Automodus, kein Messblitz-Licht zurückgeworfen, Rote-Augen-Reduzierung',
74 74
 	'EXIF_FLASH_CASE_95'		=> 'Blitz wurde ausgelöst, Automodus, Messblitz-Licht zurückgeworfen, Rote-Augen-Reduzierung',
75 75
 	'EXIF_FOCAL'				=> 'Brennweite',
76
-	'EXIF_FOCAL_EXP'			=> '%s mm',// 'EXIF_FOCAL' unit
76
+	'EXIF_FOCAL_EXP'			=> '%s mm', // 'EXIF_FOCAL' unit
77 77
 	'EXIF_ISO'					=> 'ISO-Empfindlichkeit',
78 78
 	'EXIF_METERING_MODE'		=> 'Belichtungs- Messmethode',
79 79
 	'EXIF_METERING_MODE_0'		=> 'Unbekannt',
Please login to merge, or discard this patch.
core/ext.php 1 patch
Spacing   +1 added lines, -1 removed lines patch added patch discarded remove patch
@@ -111,7 +111,7 @@
 block discarded – undo
111 111
 		{
112 112
 			$this->container->get('user')->add_lang_ext('phpbbgallery/core', 'install_gallery');
113 113
 			$error_msg = sprintf($this->container->get('user')->lang(
114
-				'GALLERY_SUB_EXT_UNINSTALL', implode('<br />', $disabled_sub_exts),count($disabled_sub_exts)));
114
+				'GALLERY_SUB_EXT_UNINSTALL', implode('<br />', $disabled_sub_exts), count($disabled_sub_exts)));
115 115
 			trigger_error($error_msg, E_USER_WARNING);
116 116
 		}
117 117
 
Please login to merge, or discard this patch.