Completed
Push — develop ( c77227...1859c0 )
by Daniel
14:00
created
services/actions/type/add.php 1 patch
Indentation   +1 added lines, -1 removed lines patch added patch discarded remove patch
@@ -51,7 +51,7 @@
 block discarded – undo
51 51
 	 * @param \blitze\sitemaker\services\auto_lang				$auto_lang				Auto add lang file
52 52
 	 * @param \blitze\content\services\form\fields_factory		$fields_factory			Fields factory  object
53 53
 	 * @param \blitze\content\services\views\views_factory		$views_factory			Views factory object
54
-	*/
54
+	 */
55 55
 	public function __construct(\phpbb\auth\auth $auth, \phpbb\controller\helper $controller_helper, \phpbb\language\language $language, \phpbb\template\template $template, \phpbb\user $user, \blitze\sitemaker\services\auto_lang $auto_lang, \blitze\content\services\form\fields_factory $fields_factory, \blitze\content\services\views\views_factory $views_factory)
56 56
 	{
57 57
 		$this->auth = $auth;
Please login to merge, or discard this patch.
controller/main_controller.php 3 patches
Doc Comments   +2 added lines, -2 removed lines patch added patch discarded remove patch
@@ -77,7 +77,7 @@  discard block
 block discarded – undo
77 77
 	 * @param string $filter_type
78 78
 	 * @param mixed $filter_value
79 79
 	 * @param int $page
80
-	 * @return \Symfony\Component\HttpFoundation\Response A Symfony Response object
80
+	 * @return string A Symfony Response object
81 81
 	 */
82 82
 	public function index($type, $_format = '', $filter_type = '', $filter_value = '', $page = 1)
83 83
 	{
@@ -162,7 +162,7 @@  discard block
 block discarded – undo
162 162
 	 * @param string $filter_type
163 163
 	 * @param mixed $filter_value
164 164
 	 * @param int $page
165
-	 * @return \Symfony\Component\HttpFoundation\Response A Symfony Response object
165
+	 * @return string A Symfony Response object
166 166
 	 */
167 167
 	public function filter($_format = '', $filter_type = '', $filter_value = '', $page = 1)
168 168
 	{
Please login to merge, or discard this patch.
Indentation   +1 added lines, -1 removed lines patch added patch discarded remove patch
@@ -54,7 +54,7 @@
 block discarded – undo
54 54
 	 * @param \blitze\content\services\feed							$feed				Feed object
55 55
 	 * @param \blitze\content\services\poll							$poll				Poll object
56 56
 	 * @param \blitze\content\services\views\views_factory			$views_factory		Views handlers
57
-	*/
57
+	 */
58 58
 	public function __construct(\phpbb\db\driver\driver_interface $db, \phpbb\controller\helper $helper, \phpbb\request\request_interface $request, \phpbb\template\template $template, \phpbb\user $user, \blitze\content\services\comments\comments_interface $comments, \blitze\content\services\types $content_types, \blitze\content\services\feed $feed, \blitze\content\services\poll $poll, \blitze\content\services\views\views_factory $views_factory)
59 59
 	{
60 60
 		$this->db = $db;
Please login to merge, or discard this patch.
Braces   +2 added lines, -4 removed lines patch added patch discarded remove patch
@@ -122,8 +122,7 @@  discard block
 block discarded – undo
122 122
 		{
123 123
 			$this->update_views($topic_id, $update_count);
124 124
 			$template_file = $view_handler->get_detail_template();
125
-		}
126
-		else
125
+		} else
127 126
 		{
128 127
 			$template_file = 'views/print.html';
129 128
 			$this->template->assign_var('TOPIC_URL', generate_board_url(true) . $topic_data['topic_url']);
@@ -244,8 +243,7 @@  discard block
 block discarded – undo
244 243
 		if ($filter_type)
245 244
 		{
246 245
 			$filters = array($filter_type => (array) $filter_value);
247
-		}
248
-		else
246
+		} else
249 247
 		{
250 248
 			$filters = $this->request->variable('filters', array('' => array('' => '')), true);
251 249
 		}
Please login to merge, or discard this patch.
event/listener.php 1 patch
Doc Comments   -1 removed lines patch added patch discarded remove patch
@@ -138,7 +138,6 @@
 block discarded – undo
138 138
 	}
139 139
 
140 140
 	/**
141
-	 * @param \phpbb\event\data $event
142 141
 	 * @return void
143 142
 	 */
144 143
 	public function load_settings_language()
Please login to merge, or discard this patch.
services/form/field/color.php 1 patch
Spacing   +3 added lines, -3 removed lines patch added patch discarded remove patch
@@ -56,7 +56,7 @@  discard block
 block discarded – undo
56 56
 	public function get_field_value(array $data)
57 57
 	{
58 58
 		$default = is_array($data['field_value']) ? $data['field_value'] : explode("\n", $data['field_value']);
59
-		$value =  $this->request->variable($name, array(0 => ''));
59
+		$value = $this->request->variable($name, array(0 => ''));
60 60
 		return $value ?: $default;
61 61
 	}
62 62
 
@@ -101,7 +101,7 @@  discard block
 block discarded – undo
101 101
 	 */
102 102
 	protected function make_box($color)
103 103
 	{
104
-		$style = 'display: inline-block; width: 15px; height: 15px; border: 1 solid #fff; border-radius: 4px; background-color: ' . $color;
105
-		return ($color) ? '<div style="' . $style . '" title="' . $color . '"></div>' : '';
104
+		$style = 'display: inline-block; width: 15px; height: 15px; border: 1 solid #fff; border-radius: 4px; background-color: '.$color;
105
+		return ($color) ? '<div style="'.$style.'" title="'.$color.'"></div>' : '';
106 106
 	}
107 107
 }
Please login to merge, or discard this patch.
services/form/field/share.php 1 patch
Spacing   +8 added lines, -8 removed lines patch added patch discarded remove patch
@@ -58,21 +58,21 @@
 block discarded – undo
58 58
 				'@blitze_content/assets/fields/display.min.js',
59 59
 			),
60 60
 			'css'	=> array(
61
-				'@blitze_content/assets/fields/share/' . $props['theme'] . '.min.css',
61
+				'@blitze_content/assets/fields/share/'.$props['theme'].'.min.css',
62 62
 			)
63 63
 		));
64 64
 
65 65
 		$classes = ['social-share', $props['corners'], $props['placement']];
66 66
 		$attributes = [
67
-			'class="' . join(' ', array_filter($classes)) . '"',
68
-			'data-show-label="' . $props['show_label'] . '"',
69
-			'data-show-count="' . $props['show_count'] . '"',
70
-			'data-share-in="' . $props['sharein'] . '"',
71
-			'data-shares="' . join(',', $props['defaults']) . '"',
72
-			'style="font-size: ' . $props['size'] . 'px"',
67
+			'class="'.join(' ', array_filter($classes)).'"',
68
+			'data-show-label="'.$props['show_label'].'"',
69
+			'data-show-count="'.$props['show_count'].'"',
70
+			'data-share-in="'.$props['sharein'].'"',
71
+			'data-shares="'.join(',', $props['defaults']).'"',
72
+			'style="font-size: '.$props['size'].'px"',
73 73
 		];
74 74
 
75
-		return '<div ' . join(' ', $attributes) . '></div>';
75
+		return '<div '.join(' ', $attributes).'></div>';
76 76
 	}
77 77
 
78 78
 	/**
Please login to merge, or discard this patch.
services/form/field/location.php 1 patch
Spacing   +10 added lines, -10 removed lines patch added patch discarded remove patch
@@ -84,7 +84,7 @@  discard block
 block discarded – undo
84 84
 		$this->util->add_assets(array(
85 85
 			'js'	=> array(
86 86
 				100 => '@blitze_content/assets/fields/form.min.js',
87
-				101 => '//maps.googleapis.com/maps/api/js?key=' . $this->google_api_key . '&libraries=places&callback=initMap&language=' . $this->language->get_used_language() . '" async defer charset="UTF-8',
87
+				101 => '//maps.googleapis.com/maps/api/js?key='.$this->google_api_key.'&libraries=places&callback=initMap&language='.$this->language->get_used_language().'" async defer charset="UTF-8',
88 88
 			)
89 89
 		));
90 90
 		$data['show_input'] = true;
@@ -103,7 +103,7 @@  discard block
 block discarded – undo
103 103
 		}
104 104
 
105 105
 		$data['field_value'] = $this->get_field_value($data);
106
-		$callable = 'display_' . $data['field_props']['disp_type'];
106
+		$callable = 'display_'.$data['field_props']['disp_type'];
107 107
 
108 108
 		return $this->$callable($data);
109 109
 	}
@@ -114,7 +114,7 @@  discard block
 block discarded – undo
114 114
 	 */
115 115
 	protected function display_address(array $data)
116 116
 	{
117
-		return $this->get_location_title($data['field_value']['place'], $data['field_value']['address']) . $data['field_value']['address'];
117
+		return $this->get_location_title($data['field_value']['place'], $data['field_value']['address']).$data['field_value']['address'];
118 118
 	}
119 119
 
120 120
 	/**
@@ -123,8 +123,8 @@  discard block
 block discarded – undo
123 123
 	 */
124 124
 	protected function display_coordinates(array $data)
125 125
 	{
126
-		return $this->get_location_title($data['field_value']['place'], $data['field_value']['address']) .
127
-			$data['field_value']['latitude'] . ', ' . $data['field_value']['longitude'];
126
+		return $this->get_location_title($data['field_value']['place'], $data['field_value']['address']).
127
+			$data['field_value']['latitude'].', '.$data['field_value']['longitude'];
128 128
 	}
129 129
 
130 130
 	/**
@@ -138,7 +138,7 @@  discard block
 block discarded – undo
138 138
 		{
139 139
 			$this->util->add_assets(array(
140 140
 				'js'	=> array(
141
-					'//maps.googleapis.com/maps/api/js?key=' . $this->google_api_key . '&callback=initMap&language=' . $this->language->get_used_language() . '" async defer charset="UTF-8',
141
+					'//maps.googleapis.com/maps/api/js?key='.$this->google_api_key.'&callback=initMap&language='.$this->language->get_used_language().'" async defer charset="UTF-8',
142 142
 					'@blitze_content/assets/fields/display.min.js',
143 143
 				)
144 144
 			));
@@ -157,18 +157,18 @@  discard block
 block discarded – undo
157 157
 		$info = $data['field_value'];
158 158
 		$settings = $data['field_props'];
159 159
 		$map_types = $settings['options'] ?: ['roadmap'];
160
-		$coordinates = $info['latitude'] . ',' . $info['longitude'];
160
+		$coordinates = $info['latitude'].','.$info['longitude'];
161 161
 
162 162
 		$params = array(
163 163
 			'center'	=> $coordinates,
164 164
 			'zoom'		=> $settings['map_zoom'] ?: $info['zoom'],
165
-			'size'		=> $settings['map_width'] . 'x' . $settings['map_height'],
165
+			'size'		=> $settings['map_width'].'x'.$settings['map_height'],
166 166
 			'maptype'	=> $info['map_type'] ?: $map_types[0],
167 167
 			'markers'	=> $coordinates,
168 168
 			'key'		=> $this->google_api_key,
169 169
 		);
170 170
 
171
-		return '<img src="https://maps.googleapis.com/maps/api/staticmap?' . http_build_query($params) . '" alt="' . $info['address'] . '" title="' . $info['place'] . '" />';
171
+		return '<img src="https://maps.googleapis.com/maps/api/staticmap?'.http_build_query($params).'" alt="'.$info['address'].'" title="'.$info['place'].'" />';
172 172
 	}
173 173
 
174 174
 	/**
@@ -178,6 +178,6 @@  discard block
 block discarded – undo
178 178
 	 */
179 179
 	protected function get_location_title($place, $address)
180 180
 	{
181
-		return (strpos($address, $place) === false) ? '<strong>' . $place . '</strong><br />' : '';
181
+		return (strpos($address, $place) === false) ? '<strong>'.$place.'</strong><br />' : '';
182 182
 	}
183 183
 }
Please login to merge, or discard this patch.
services/form/field/textarea.php 1 patch
Spacing   +6 added lines, -6 removed lines patch added patch discarded remove patch
@@ -94,9 +94,9 @@  discard block
 block discarded – undo
94 94
 	{
95 95
 		$toc_pattern = '(<h4>(.*?)</h4>)?';
96 96
 		$pages_pattern = '<p><!-- pagebreak --></p>';
97
-		$split_pattern = $pages_pattern . (($view_mode !== 'detail') ? $toc_pattern : '');
97
+		$split_pattern = $pages_pattern.(($view_mode !== 'detail') ? $toc_pattern : '');
98 98
 
99
-		$pages = array_filter(preg_split('#' . $split_pattern . '#s', $data['field_value']));
99
+		$pages = array_filter(preg_split('#'.$split_pattern.'#s', $data['field_value']));
100 100
 
101 101
 		if ($view_mode !== 'detail')
102 102
 		{
@@ -104,7 +104,7 @@  discard block
 block discarded – undo
104 104
 		}
105 105
 
106 106
 		// get page titles to generate TOC
107
-		preg_match_all('#' . $pages_pattern . $toc_pattern . '#s', $data['field_value'], $matches);
107
+		preg_match_all('#'.$pages_pattern.$toc_pattern.'#s', $data['field_value'], $matches);
108 108
 
109 109
 		return $this->get_detail_value($pages, $matches[2], $data);
110 110
 	}
@@ -119,7 +119,7 @@  discard block
 block discarded – undo
119 119
 			$asset_path = $this->util->get_web_path();
120 120
 			$this->util->add_assets(array(
121 121
 				'js'   => array(
122
-					$asset_path . 'assets/javascript/editor.js',
122
+					$asset_path.'assets/javascript/editor.js',
123 123
 					'@blitze_content/assets/fields/textarea.min.js'
124 124
 				)
125 125
 			));
@@ -227,7 +227,7 @@  discard block
 block discarded – undo
227 227
 				$this->template->assign_block_vars('toc', array(
228 228
 					'TITLE'		=> ($title) ? $title : $this->language->lang('CONTENT_TOC_UNTITLED'),
229 229
 					'S_PAGE'	=> ($page === $start),
230
-					'U_VIEW'	=> append_sid($topic_url, ($page) ? 'page=' . $page : false),
230
+					'U_VIEW'	=> append_sid($topic_url, ($page) ? 'page='.$page : false),
231 231
 				));
232 232
 			}
233 233
 		}
@@ -279,7 +279,7 @@  discard block
 block discarded – undo
279 279
 		// Assigning custom bbcodes
280 280
 		if (!function_exists('display_custom_bbcodes'))
281 281
 		{
282
-			include($this->phpbb_root_path . 'includes/functions_display.' . $this->php_ext);
282
+			include($this->phpbb_root_path.'includes/functions_display.'.$this->php_ext);
283 283
 		}
284 284
 
285 285
 		display_custom_bbcodes();
Please login to merge, or discard this patch.
services/form/field/image.php 1 patch
Spacing   +7 added lines, -7 removed lines patch added patch discarded remove patch
@@ -52,7 +52,7 @@  discard block
 block discarded – undo
52 52
 		$value = $this->request->variable($data['field_name'], $data['field_value']);
53 53
 		$value = $this->get_image_src($value);
54 54
 
55
-		return ($value) ? '[img]' . $value . '[/img]' : '';
55
+		return ($value) ? '[img]'.$value.'[/img]' : '';
56 56
 	}
57 57
 
58 58
 	/**
@@ -77,7 +77,7 @@  discard block
 block discarded – undo
77 77
 
78 78
 		$this->set_filemanager($data);
79 79
 		$this->ptemplate->assign_vars($data);
80
-		$field = $this->ptemplate->render_view('blitze/content', "fields/image.html", $field . '_field');
80
+		$field = $this->ptemplate->render_view('blitze/content', "fields/image.html", $field.'_field');
81 81
 
82 82
 		$data['field_value'] = $bbcode_value;
83 83
 
@@ -136,14 +136,14 @@  discard block
 block discarded – undo
136 136
 	 */
137 137
 	private function get_image_html($image, $mode, array $field_props)
138 138
 	{
139
-		$image = $image ?: '<img src="' . $field_props['default'] . '" class="postimage" alt="Image" />';
139
+		$image = $image ?: '<img src="'.$field_props['default'].'" class="postimage" alt="Image" />';
140 140
 
141
-		$html = '<figure class="img-ui">' . $image . '</figure>';
141
+		$html = '<figure class="img-ui">'.$image.'</figure>';
142 142
 		if ($mode !== 'block')
143 143
 		{
144
-			$view_props = array_fill_keys(array($mode . '_size', $mode . '_align'), '');
144
+			$view_props = array_fill_keys(array($mode.'_size', $mode.'_align'), '');
145 145
 			$image_props = array_filter(array_intersect_key($field_props, $view_props));
146
-			$html = '<div class="' . join(' ', $image_props) . '">' . $html . '</div>';
146
+			$html = '<div class="'.join(' ', $image_props).'">'.$html.'</div>';
147 147
 		}
148 148
 		return $html;
149 149
 	}
@@ -158,7 +158,7 @@  discard block
 block discarded – undo
158 158
 		{
159 159
 			$data['filemanager_path'] = append_sid("{$this->phpbb_root_path}ResponsiveFilemanager/filemanager/dialog.$this->php_ext", array(
160 160
 				'type'			=> 1,
161
-				'field_id'		=> 'smc-' . $data['field_name'],
161
+				'field_id'		=> 'smc-'.$data['field_name'],
162 162
 				'akey'			=> $this->filemanager->get_access_key(),
163 163
 			));
164 164
 		}
Please login to merge, or discard this patch.
services/views/driver/base_view.php 1 patch
Spacing   +4 added lines, -4 removed lines patch added patch discarded remove patch
@@ -134,7 +134,7 @@  discard block
 block discarded – undo
134 134
 
135 135
 		foreach ($posts_data as $topic_id => $posts)
136 136
 		{
137
-			$post_data	= array_shift($posts);
137
+			$post_data = array_shift($posts);
138 138
 			$topic_data	= $topics_data[$topic_id];
139 139
 			$topic_data = array_merge(
140 140
 				$this->fields->show($content_type, $topic_data, $post_data, $users_cache, $attachments, $update_count, $topic_tracking_info),
@@ -248,8 +248,8 @@  discard block
 block discarded – undo
248 248
 		$this->pagination->generate_template_pagination(
249 249
 			array(
250 250
 				'routes' => array(
251
-					'blitze_content_' . $route_type,
252
-					'blitze_content_' . $route_type . '_page',
251
+					'blitze_content_'.$route_type,
252
+					'blitze_content_'.$route_type.'_page',
253 253
 				),
254 254
 				'params' => $params,
255 255
 			),
@@ -340,7 +340,7 @@  discard block
 block discarded – undo
340 340
 				->fetch_forum($topic_data['forum_id'])
341 341
 				->fetch_topic_poster($topic_data['topic_poster'])
342 342
 				->fetch_custom(array(
343
-					'WHERE' => array('t.topic_id <> ' . (int) $topic_data['topic_id'])
343
+					'WHERE' => array('t.topic_id <> '.(int) $topic_data['topic_id'])
344 344
 				))->build(true, true, false);
345 345
 
346 346
 			$topics_data = $this->forum->get_topic_data(5);
Please login to merge, or discard this patch.