GitHub Access Token became invalid

It seems like the GitHub access token used for retrieving details about this repository from GitHub became invalid. This might prevent certain types of inspections from being run (in particular, everything related to pull requests).
Please ask an admin of your repository to re-new the access token on this website.
Completed
Push — master ( 423fe8...f48289 )
by gyeong-won
15:56 queued 08:14
created
modules/member/member.admin.model.php 2 patches
Braces   +45 added lines, -18 removed lines patch added patch discarded remove patch
@@ -63,20 +63,28 @@  discard block
 block discarded – undo
63 63
 			switch($search_target)
64 64
 			{
65 65
 				case 'user_id' :
66
-					if($search_keyword) $search_keyword = str_replace(' ','%',$search_keyword);
66
+					if($search_keyword) {
67
+						$search_keyword = str_replace(' ','%',$search_keyword);
68
+					}
67 69
 					$args->s_user_id = $search_keyword;
68 70
 					break;
69 71
 				case 'user_name' :
70
-					if($search_keyword) $search_keyword = str_replace(' ','%',$search_keyword);
72
+					if($search_keyword) {
73
+						$search_keyword = str_replace(' ','%',$search_keyword);
74
+					}
71 75
 					$args->s_user_name = $search_keyword;
72 76
 					break;
73 77
 				case 'nick_name' :
74
-					if($search_keyword) $search_keyword = str_replace(' ','%',$search_keyword);
78
+					if($search_keyword) {
79
+						$search_keyword = str_replace(' ','%',$search_keyword);
80
+					}
75 81
 					$args->s_nick_name = $search_keyword;
76 82
 					$args->html_nick_name = htmlspecialchars($search_keyword, ENT_COMPAT | ENT_HTML401, 'UTF-8', false);
77 83
 					break;
78 84
 				case 'email_address' :
79
-					if($search_keyword) $search_keyword = str_replace(' ','%',$search_keyword);
85
+					if($search_keyword) {
86
+						$search_keyword = str_replace(' ','%',$search_keyword);
87
+					}
80 88
 					$args->s_email_address = $search_keyword;
81 89
 					break;
82 90
 				case 'regdate' :
@@ -129,8 +137,7 @@  discard block
 block discarded – undo
129 137
 		{
130 138
 			$query_id = 'member.getMemberListWithinGroup';
131 139
 			$args->sort_index = "member.".$sort_index;
132
-		}
133
-		else
140
+		} else
134 141
 		{
135 142
 			$query_id = 'member.getMemberList';
136 143
 			$args->sort_index = $sort_index; 
@@ -174,7 +181,9 @@  discard block
 block discarded – undo
174 181
 	function getSiteAdminMemberSrls()
175 182
 	{
176 183
 		$output = executeQueryArray('member.getSiteAdminMemberSrls');
177
-		if(!$output->toBool() || !$output->data) return array();
184
+		if(!$output->toBool() || !$output->data) {
185
+			return array();
186
+		}
178 187
 
179 188
 		$member_srls = array();
180 189
 		foreach($output->data as $member_info)
@@ -193,8 +202,9 @@  discard block
 block discarded – undo
193 202
 	function getMemberAdminColorset()
194 203
 	{
195 204
 		$skin = Context::get('skin');
196
-		if(!$skin) $tpl = "";
197
-		else
205
+		if(!$skin) {
206
+			$tpl = "";
207
+		} else
198 208
 		{
199 209
 			$oModuleModel = getModel('module');
200 210
 			$skin_info = $oModuleModel->loadSkinInfo($this->module_path, $skin);
@@ -202,7 +212,9 @@  discard block
 block discarded – undo
202 212
 
203 213
 			$oModuleModel = getModel('module');
204 214
 			$config = $oModuleModel->getModuleConfig('member');
205
-			if(!$config->colorset) $config->colorset = "white";
215
+			if(!$config->colorset) {
216
+				$config->colorset = "white";
217
+			}
206 218
 			Context::set('config', $config);
207 219
 
208 220
 			$oTemplate = &TemplateHandler::getInstance();
@@ -223,10 +235,14 @@  discard block
 block discarded – undo
223 235
 	public function getMemberCountByDate($date = '')
224 236
 	{
225 237
 		$args = new stdClass();
226
-		if($date) $args->regDate = date('Ymd', strtotime($date));
238
+		if($date) {
239
+			$args->regDate = date('Ymd', strtotime($date));
240
+		}
227 241
 
228 242
 		$output = executeQuery('member.getMemberCountByDate', $args);
229
-		if(!$output->toBool()) return 0;
243
+		if(!$output->toBool()) {
244
+			return 0;
245
+		}
230 246
 
231 247
 		return $output->data->count;
232 248
 	}
@@ -240,10 +256,14 @@  discard block
 block discarded – undo
240 256
 	 */
241 257
 	function getMemberGroupMemberCountByDate($date = '')
242 258
 	{
243
-		if($date) $args->regDate = date('Ymd', strtotime($date));
259
+		if($date) {
260
+			$args->regDate = date('Ymd', strtotime($date));
261
+		}
244 262
 
245 263
 		$output = executeQuery('member.getMemberGroupMemberCountByDate', $args);
246
-		if(!$output->toBool()) return 0;
264
+		if(!$output->toBool()) {
265
+			return 0;
266
+		}
247 267
 
248 268
 		return count($output->data);
249 269
 	}
@@ -298,10 +318,17 @@  discard block
 block discarded – undo
298 318
 	{
299 319
 		$db_info = Context::getDBInfo();
300 320
 		$admin_ip_list = $db_info->admin_ip_list;
301
-		if(!$admin_ip_list) return true;
302
-		if(!is_array($admin_ip_list)) $admin_ip_list = explode(',',$admin_ip_list);
303
-		if(!count($admin_ip_list) || IpFilter::filter($admin_ip_list)) return true;
304
-		else return false;
321
+		if(!$admin_ip_list) {
322
+			return true;
323
+		}
324
+		if(!is_array($admin_ip_list)) {
325
+			$admin_ip_list = explode(',',$admin_ip_list);
326
+		}
327
+		if(!count($admin_ip_list) || IpFilter::filter($admin_ip_list)) {
328
+			return true;
329
+		} else {
330
+			return false;
331
+		}
305 332
 	}
306 333
 }
307 334
 /* End of file member.admin.model.php */
Please login to merge, or discard this patch.
Spacing   +41 added lines, -41 removed lines patch added patch discarded remove patch
@@ -42,64 +42,64 @@  discard block
 block discarded – undo
42 42
 	{
43 43
 		// Search option
44 44
 		$args = new stdClass();
45
-		$args->is_admin = Context::get('is_admin')=='Y'?'Y':'';
46
-		$args->is_denied = Context::get('is_denied')=='Y'?'Y':'';
45
+		$args->is_admin = Context::get('is_admin') == 'Y' ? 'Y' : '';
46
+		$args->is_denied = Context::get('is_denied') == 'Y' ? 'Y' : '';
47 47
 		$args->selected_group_srl = Context::get('selected_group_srl');
48 48
 
49 49
 		$filter = Context::get('filter_type');
50
-		switch($filter)
50
+		switch ($filter)
51 51
 		{
52
-			case 'super_admin' : $args->is_admin = 'Y';break;
53
-			case 'site_admin' : $args->member_srls = $this->getSiteAdminMemberSrls();break;
54
-			case 'enable' : $args->is_denied = 'N';break;
55
-			case 'disable' : $args->is_denied = 'Y';break;
52
+			case 'super_admin' : $args->is_admin = 'Y'; break;
53
+			case 'site_admin' : $args->member_srls = $this->getSiteAdminMemberSrls(); break;
54
+			case 'enable' : $args->is_denied = 'N'; break;
55
+			case 'disable' : $args->is_denied = 'Y'; break;
56 56
 		}
57 57
 
58 58
 		$search_target = trim(Context::get('search_target'));
59 59
 		$search_keyword = trim(Context::get('search_keyword'));
60 60
 
61
-		if($search_target && $search_keyword)
61
+		if ($search_target && $search_keyword)
62 62
 		{
63
-			switch($search_target)
63
+			switch ($search_target)
64 64
 			{
65 65
 				case 'user_id' :
66
-					if($search_keyword) $search_keyword = str_replace(' ','%',$search_keyword);
66
+					if ($search_keyword) $search_keyword = str_replace(' ', '%', $search_keyword);
67 67
 					$args->s_user_id = $search_keyword;
68 68
 					break;
69 69
 				case 'user_name' :
70
-					if($search_keyword) $search_keyword = str_replace(' ','%',$search_keyword);
70
+					if ($search_keyword) $search_keyword = str_replace(' ', '%', $search_keyword);
71 71
 					$args->s_user_name = $search_keyword;
72 72
 					break;
73 73
 				case 'nick_name' :
74
-					if($search_keyword) $search_keyword = str_replace(' ','%',$search_keyword);
74
+					if ($search_keyword) $search_keyword = str_replace(' ', '%', $search_keyword);
75 75
 					$args->s_nick_name = $search_keyword;
76 76
 					$args->html_nick_name = htmlspecialchars($search_keyword, ENT_COMPAT | ENT_HTML401, 'UTF-8', false);
77 77
 					break;
78 78
 				case 'email_address' :
79
-					if($search_keyword) $search_keyword = str_replace(' ','%',$search_keyword);
79
+					if ($search_keyword) $search_keyword = str_replace(' ', '%', $search_keyword);
80 80
 					$args->s_email_address = $search_keyword;
81 81
 					break;
82 82
 				case 'regdate' :
83
-					$args->s_regdate = preg_replace("/[^0-9]/","",$search_keyword);
83
+					$args->s_regdate = preg_replace("/[^0-9]/", "", $search_keyword);
84 84
 					break;
85 85
 				case 'regdate_more' :
86
-					$args->s_regdate_more = substr(preg_replace("/[^0-9]/","",$search_keyword) . '00000000000000',0,14);
86
+					$args->s_regdate_more = substr(preg_replace("/[^0-9]/", "", $search_keyword).'00000000000000', 0, 14);
87 87
 					break;
88 88
 				case 'regdate_less' :
89
-					$args->s_regdate_less = substr(preg_replace("/[^0-9]/","",$search_keyword) . '00000000000000',0,14);
89
+					$args->s_regdate_less = substr(preg_replace("/[^0-9]/", "", $search_keyword).'00000000000000', 0, 14);
90 90
 					break;
91 91
 				case 'last_login' :
92
-					$args->s_last_login = preg_replace("/[^0-9]/","",$search_keyword);
92
+					$args->s_last_login = preg_replace("/[^0-9]/", "", $search_keyword);
93 93
 					//$args->s_last_login = $search_keyword;
94 94
 					break;
95 95
 				case 'last_login_more' :
96
-					$args->s_last_login_more = substr(preg_replace("/[^0-9]/","",$search_keyword) . '00000000000000',0,14);
96
+					$args->s_last_login_more = substr(preg_replace("/[^0-9]/", "", $search_keyword).'00000000000000', 0, 14);
97 97
 					break;
98 98
 				case 'last_login_less' :
99
-					$args->s_last_login_less = substr(preg_replace("/[^0-9]/","",$search_keyword) . '00000000000000',0,14);
99
+					$args->s_last_login_less = substr(preg_replace("/[^0-9]/", "", $search_keyword).'00000000000000', 0, 14);
100 100
 					break;
101 101
 				case 'birthday' :
102
-					$args->s_birthday = preg_replace("/[^0-9]/","",$search_keyword);
102
+					$args->s_birthday = preg_replace("/[^0-9]/", "", $search_keyword);
103 103
 					break;
104 104
 				case 'extra_vars' :
105 105
 					$args->s_extra_vars = $search_keyword;
@@ -110,22 +110,22 @@  discard block
 block discarded – undo
110 110
 		// Change the query id if selected_group_srl exists (for table join)
111 111
 		$sort_order = Context::get('sort_order');
112 112
 		$sort_index = Context::get('sort_index');
113
-		if(!$sort_index)
113
+		if (!$sort_index)
114 114
 		{
115 115
 			$sort_index = "list_order";
116 116
 		}
117 117
 
118
-		if(!$sort_order)
118
+		if (!$sort_order)
119 119
 		{
120 120
 			$sort_order = 'asc';
121 121
 		}
122 122
 
123
-		if($sort_order != 'asc')
123
+		if ($sort_order != 'asc')
124 124
 		{
125 125
 			$sort_order = 'desc';
126 126
 		}
127 127
 
128
-		if($args->selected_group_srl)
128
+		if ($args->selected_group_srl)
129 129
 		{
130 130
 			$query_id = 'member.getMemberListWithinGroup';
131 131
 			$args->sort_index = "member.".$sort_index;
@@ -174,10 +174,10 @@  discard block
 block discarded – undo
174 174
 	function getSiteAdminMemberSrls()
175 175
 	{
176 176
 		$output = executeQueryArray('member.getSiteAdminMemberSrls');
177
-		if(!$output->toBool() || !$output->data) return array();
177
+		if (!$output->toBool() || !$output->data) return array();
178 178
 
179 179
 		$member_srls = array();
180
-		foreach($output->data as $member_info)
180
+		foreach ($output->data as $member_info)
181 181
 		{
182 182
 			$member_srls[] = $member_info->member_srl;
183 183
 		}
@@ -193,7 +193,7 @@  discard block
 block discarded – undo
193 193
 	function getMemberAdminColorset()
194 194
 	{
195 195
 		$skin = Context::get('skin');
196
-		if(!$skin) $tpl = "";
196
+		if (!$skin) $tpl = "";
197 197
 		else
198 198
 		{
199 199
 			$oModuleModel = getModel('module');
@@ -202,7 +202,7 @@  discard block
 block discarded – undo
202 202
 
203 203
 			$oModuleModel = getModel('module');
204 204
 			$config = $oModuleModel->getModuleConfig('member');
205
-			if(!$config->colorset) $config->colorset = "white";
205
+			if (!$config->colorset) $config->colorset = "white";
206 206
 			Context::set('config', $config);
207 207
 
208 208
 			$oTemplate = &TemplateHandler::getInstance();
@@ -223,10 +223,10 @@  discard block
 block discarded – undo
223 223
 	public function getMemberCountByDate($date = '')
224 224
 	{
225 225
 		$args = new stdClass();
226
-		if($date) $args->regDate = date('Ymd', strtotime($date));
226
+		if ($date) $args->regDate = date('Ymd', strtotime($date));
227 227
 
228 228
 		$output = executeQuery('member.getMemberCountByDate', $args);
229
-		if(!$output->toBool()) return 0;
229
+		if (!$output->toBool()) return 0;
230 230
 
231 231
 		return $output->data->count;
232 232
 	}
@@ -240,10 +240,10 @@  discard block
 block discarded – undo
240 240
 	 */
241 241
 	function getMemberGroupMemberCountByDate($date = '')
242 242
 	{
243
-		if($date) $args->regDate = date('Ymd', strtotime($date));
243
+		if ($date) $args->regDate = date('Ymd', strtotime($date));
244 244
 
245 245
 		$output = executeQuery('member.getMemberGroupMemberCountByDate', $args);
246
-		if(!$output->toBool()) return 0;
246
+		if (!$output->toBool()) return 0;
247 247
 
248 248
 		return count($output->data);
249 249
 	}
@@ -261,11 +261,11 @@  discard block
 block discarded – undo
261 261
 		$args->member_join_form_srl = $member_join_form_srl;
262 262
 		$output = executeQuery('member.getJoinForm', $args);
263 263
 
264
-		if($output->toBool() && $output->data)
264
+		if ($output->toBool() && $output->data)
265 265
 		{
266 266
 			$formInfo = $output->data;
267 267
 			$default_value = $formInfo->default_value;
268
-			if($default_value)
268
+			if ($default_value)
269 269
 			{
270 270
 				$default_value = unserialize($default_value);
271 271
 				Context::set('default_value', $default_value);
@@ -275,18 +275,18 @@  discard block
 block discarded – undo
275 275
 
276 276
 		$oMemberModel = getModel('member');
277 277
 		$config = $oMemberModel->getMemberConfig();
278
-		foreach($config->signupForm as $item) 
278
+		foreach ($config->signupForm as $item) 
279 279
 		{
280 280
 			$list[] = $item->name;
281 281
 		}
282 282
 
283
-		$id_list = implode(',',$list);
284
-		Context::set('id_list',$id_list);
283
+		$id_list = implode(',', $list);
284
+		Context::set('id_list', $id_list);
285 285
 
286 286
 		$oTemplate = &TemplateHandler::getInstance();
287 287
 		$tpl = $oTemplate->compile($this->module_path.'tpl', 'insert_join_form');
288 288
 
289
-		$this->add('tpl', str_replace("\n"," ",$tpl));
289
+		$this->add('tpl', str_replace("\n", " ", $tpl));
290 290
 	}
291 291
 
292 292
 	/**
@@ -298,9 +298,9 @@  discard block
 block discarded – undo
298 298
 	{
299 299
 		$db_info = Context::getDBInfo();
300 300
 		$admin_ip_list = $db_info->admin_ip_list;
301
-		if(!$admin_ip_list) return true;
302
-		if(!is_array($admin_ip_list)) $admin_ip_list = explode(',',$admin_ip_list);
303
-		if(!count($admin_ip_list) || IpFilter::filter($admin_ip_list)) return true;
301
+		if (!$admin_ip_list) return true;
302
+		if (!is_array($admin_ip_list)) $admin_ip_list = explode(',', $admin_ip_list);
303
+		if (!count($admin_ip_list) || IpFilter::filter($admin_ip_list)) return true;
304 304
 		else return false;
305 305
 	}
306 306
 }
Please login to merge, or discard this patch.
modules/member/member.mobile.php 2 patches
Braces   +2 added lines, -4 removed lines patch added patch discarded remove patch
@@ -25,8 +25,7 @@  discard block
 block discarded – undo
25 25
 		{
26 26
 			$mskin = 'default';
27 27
 			$template_path = sprintf('%sm.skins/%s', $this->module_path, $mskin);
28
-		}
29
-		else
28
+		} else
30 29
 		{
31 30
 			$template_path = sprintf('%sm.skins/%s', $this->module_path, $mskin);
32 31
 		}
@@ -40,8 +39,7 @@  discard block
 block discarded – undo
40 39
 			if(!$this->memberInfo)
41 40
 			{
42 41
 				Context::set('member_srl','');
43
-			}
44
-			else
42
+			} else
45 43
 			{
46 44
 				Context::set('member_info',$this->memberInfo);
47 45
 			}
Please login to merge, or discard this patch.
Spacing   +7 added lines, -7 removed lines patch added patch discarded remove patch
@@ -21,7 +21,7 @@  discard block
 block discarded – undo
21 21
 
22 22
 		$mskin = $this->member_config->mskin;
23 23
 		// Set the template path
24
-		if(!$mskin)
24
+		if (!$mskin)
25 25
 		{
26 26
 			$mskin = 'default';
27 27
 			$template_path = sprintf('%sm.skins/%s', $this->module_path, $mskin);
@@ -33,17 +33,17 @@  discard block
 block discarded – undo
33 33
 
34 34
 		// if member_srl exists, set memberInfo
35 35
 		$member_srl = Context::get('member_srl');
36
-		if($member_srl)
36
+		if ($member_srl)
37 37
 		{
38 38
 			$oMemberModel = getModel('member');
39 39
 			$this->memberInfo = $oMemberModel->getMemberInfoByMemberSrl($member_srl);
40
-			if(!$this->memberInfo)
40
+			if (!$this->memberInfo)
41 41
 			{
42
-				Context::set('member_srl','');
42
+				Context::set('member_srl', '');
43 43
 			}
44 44
 			else
45 45
 			{
46
-				Context::set('member_info',$this->memberInfo);
46
+				Context::set('member_info', $this->memberInfo);
47 47
 			}
48 48
 		}
49 49
 
@@ -51,7 +51,7 @@  discard block
 block discarded – undo
51 51
 
52 52
 		$oLayoutModel = getModel('layout');
53 53
 		$layout_info = $oLayoutModel->getLayout($this->member_config->mlayout_srl);
54
-		if($layout_info)
54
+		if ($layout_info)
55 55
 		{
56 56
 			$this->module_info->mlayout_srl = $this->member_config->mlayout_srl;
57 57
 			$this->setLayoutPath($layout_info->path);
@@ -62,7 +62,7 @@  discard block
 block discarded – undo
62 62
 	{
63 63
 		parent::dispMemberModifyInfo();
64 64
 
65
-		if($this->member_info)
65
+		if ($this->member_info)
66 66
 		{
67 67
 			Context::set('oMemberInfo', get_object_vars($this->member_info));
68 68
 		}
Please login to merge, or discard this patch.
modules/menu/menu.admin.view.php 2 patches
Braces   +15 added lines, -8 removed lines patch added patch discarded remove patch
@@ -36,8 +36,11 @@  discard block
 block discarded – undo
36 36
 
37 37
 		if(!$site_srl)
38 38
 		{
39
-			if($logged_info->is_admin == 'Y' && !$site_keyword) $site_srl = 0;
40
-			else $site_srl = (int)$site_module_info->site_srl;
39
+			if($logged_info->is_admin == 'Y' && !$site_keyword) {
40
+				$site_srl = 0;
41
+			} else {
42
+				$site_srl = (int)$site_module_info->site_srl;
43
+			}
41 44
 		}
42 45
 
43 46
 		// process for unlinked modules
@@ -51,7 +54,9 @@  discard block
 block discarded – undo
51 54
 
52 55
 		$oMenuAdminModel = getAdminModel('menu');
53 56
 		$menuListFromDB = $oMenuAdminModel->getMenus();
54
-		if(is_array($menuListFromDB)) $output = array_reverse($menuListFromDB);
57
+		if(is_array($menuListFromDB)) {
58
+			$output = array_reverse($menuListFromDB);
59
+		}
55 60
 
56 61
 		$menuList = array();
57 62
 		if(is_array($output))
@@ -59,13 +64,16 @@  discard block
 block discarded – undo
59 64
 			$menuItems = array();
60 65
 			foreach($output as $key=>$value)
61 66
 			{
62
-				if($value->title == $oAdmin->getAdminMenuName()) unset($output[$key]);
63
-				else
67
+				if($value->title == $oAdmin->getAdminMenuName()) {
68
+					unset($output[$key]);
69
+				} else
64 70
 				{
65 71
 					unset($menu, $menuItems);
66 72
 					//$value->xml_file = sprintf('./files/cache/menu/%s.xml.php',$value->menu_srl);
67 73
 					$value->php_file = sprintf(_XE_PATH_ . 'files/cache/menu/%s.php',$value->menu_srl);
68
-					if(file_exists($value->php_file)) include($value->php_file);
74
+					if(file_exists($value->php_file)) {
75
+						include($value->php_file);
76
+					}
69 77
 
70 78
 					if(count($menu->list)>0)
71 79
 					{
@@ -102,8 +110,7 @@  discard block
 block discarded – undo
102 110
 		{
103 111
 			include($theme_file);
104 112
 			Context::set('current_layout', $theme_info->layout);
105
-		}
106
-		else
113
+		} else
107 114
 		{
108 115
 			$oModuleModel = getModel('module');
109 116
 			$default_mid = $oModuleModel->getDefaultMid();
Please login to merge, or discard this patch.
Spacing   +23 added lines, -23 removed lines patch added patch discarded remove patch
@@ -34,14 +34,14 @@  discard block
 block discarded – undo
34 34
 		$site_srl = Context::get('site_srl');
35 35
 		$site_module_info = Context::get('site_module_info');
36 36
 
37
-		if(!$site_srl)
37
+		if (!$site_srl)
38 38
 		{
39
-			if($logged_info->is_admin == 'Y' && !$site_keyword) $site_srl = 0;
40
-			else $site_srl = (int)$site_module_info->site_srl;
39
+			if ($logged_info->is_admin == 'Y' && !$site_keyword) $site_srl = 0;
40
+			else $site_srl = (int) $site_module_info->site_srl;
41 41
 		}
42 42
 
43 43
 		// process for unlinked modules
44
-		if($site_srl == 0)
44
+		if ($site_srl == 0)
45 45
 		{
46 46
 			$oMenuController = getAdminController('menu');
47 47
 			$oMenuController->linkAllModuleInstancesToSitemap();
@@ -51,25 +51,25 @@  discard block
 block discarded – undo
51 51
 
52 52
 		$oMenuAdminModel = getAdminModel('menu');
53 53
 		$menuListFromDB = $oMenuAdminModel->getMenus();
54
-		if(is_array($menuListFromDB)) $output = array_reverse($menuListFromDB);
54
+		if (is_array($menuListFromDB)) $output = array_reverse($menuListFromDB);
55 55
 
56 56
 		$menuList = array();
57
-		if(is_array($output))
57
+		if (is_array($output))
58 58
 		{
59 59
 			$menuItems = array();
60
-			foreach($output as $key=>$value)
60
+			foreach ($output as $key=>$value)
61 61
 			{
62
-				if($value->title == $oAdmin->getAdminMenuName()) unset($output[$key]);
62
+				if ($value->title == $oAdmin->getAdminMenuName()) unset($output[$key]);
63 63
 				else
64 64
 				{
65 65
 					unset($menu, $menuItems);
66 66
 					//$value->xml_file = sprintf('./files/cache/menu/%s.xml.php',$value->menu_srl);
67
-					$value->php_file = sprintf(_XE_PATH_ . 'files/cache/menu/%s.php',$value->menu_srl);
68
-					if(file_exists($value->php_file)) include($value->php_file);
67
+					$value->php_file = sprintf(_XE_PATH_.'files/cache/menu/%s.php', $value->menu_srl);
68
+					if (file_exists($value->php_file)) include($value->php_file);
69 69
 
70
-					if(count($menu->list)>0)
70
+					if (count($menu->list) > 0)
71 71
 					{
72
-						foreach($menu->list as $key2=>$value2)
72
+						foreach ($menu->list as $key2=>$value2)
73 73
 						{
74 74
 							$this->_menuInfoSetting($menu->list[$key2]);
75 75
 						}
@@ -98,7 +98,7 @@  discard block
 block discarded – undo
98 98
 
99 99
 		// choice theme file
100 100
 		$theme_file = _XE_PATH_.'files/theme/theme_info.php';
101
-		if(is_readable($theme_file))
101
+		if (is_readable($theme_file))
102 102
 		{
103 103
 			include($theme_file);
104 104
 			Context::set('current_layout', $theme_info->layout);
@@ -113,10 +113,10 @@  discard block
 block discarded – undo
113 113
 		// get default group list
114 114
 		$oMemberModel = getModel('member');
115 115
 		$output = $oMemberModel->getGroups();
116
-		if(is_array($output))
116
+		if (is_array($output))
117 117
 		{
118 118
 			$groupList = array();
119
-			foreach($output as $value)
119
+			foreach ($output as $value)
120 120
 			{
121 121
 				$groupList[$value->group_srl] = new stdClass();
122 122
 				$groupList[$value->group_srl]->group_srl = $value->group_srl;
@@ -145,13 +145,13 @@  discard block
 block discarded – undo
145 145
 	function _menuInfoSetting(&$menu)
146 146
 	{
147 147
 		$oModuleModel = getModel('module');
148
-		if($menu['url'] && strncasecmp('http', $menu['url'], 4) !== 0)
148
+		if ($menu['url'] && strncasecmp('http', $menu['url'], 4) !== 0)
149 149
 		{
150 150
 			unset($midInfo);
151 151
 			unset($moduleInfo);
152 152
 			$midInfo = $oModuleModel->getModuleInfoByMid($menu['url'], 0);
153 153
 			$moduleInfo = $oModuleModel->getModuleInfoXml($midInfo->module);
154
-			if($moduleInfo->setup_index_act)
154
+			if ($moduleInfo->setup_index_act)
155 155
 			{
156 156
 				$menu['module_srl'] = $midInfo->module_srl;
157 157
 				$menu['setup_index_act'] = $moduleInfo->setup_index_act;
@@ -159,9 +159,9 @@  discard block
 block discarded – undo
159 159
 			// setting layout srl for layout management
160 160
 			$menu['layout_srl'] = $midInfo->layout_srl;
161 161
 		}
162
-		if(count($menu['list']) > 0)
162
+		if (count($menu['list']) > 0)
163 163
 		{
164
-			foreach($menu['list'] as $key=>$value)
164
+			foreach ($menu['list'] as $key=>$value)
165 165
 			{
166 166
 				$this->_menuInfoSetting($menu['list'][$key]);
167 167
 			}
@@ -175,17 +175,17 @@  discard block
 block discarded – undo
175 175
 	 */
176 176
 	function _arrangeMenuItem($menuItems)
177 177
 	{
178
-		if(is_array($menuItems))
178
+		if (is_array($menuItems))
179 179
 		{
180 180
 			$arrangedMenuItemList = array();
181
-			foreach($menuItems as $value)
181
+			foreach ($menuItems as $value)
182 182
 			{
183
-				if($value->parent_srl == 0)
183
+				if ($value->parent_srl == 0)
184 184
 				{
185 185
 					$arrangedMenuItemList[$value->menu_item_srl] = array('name'=>$value->name, 'subMenu'=>array());
186 186
 				}
187 187
 
188
-				if($value->parent_srl > 0 && isset($arrangedMenuItemList[$value->parent_srl]))
188
+				if ($value->parent_srl > 0 && isset($arrangedMenuItemList[$value->parent_srl]))
189 189
 				{
190 190
 					$arrangedMenuItemList[$value->parent_srl]['subMenu'][$value->menu_item_srl] = $value;
191 191
 				}
Please login to merge, or discard this patch.
modules/message/message.admin.controller.php 2 patches
Spacing   +2 added lines, -2 removed lines patch added patch discarded remove patch
@@ -23,8 +23,8 @@
 block discarded – undo
23 23
 		$args = Context::gets('skin', 'mskin', 'colorset', 'mcolorset');
24 24
 		// Create a module Controller object
25 25
 		$oModuleController = getController('module');
26
-		$output = $oModuleController->insertModuleConfig('message',$args);
27
-		if(!$output->toBool()) return $output;
26
+		$output = $oModuleController->insertModuleConfig('message', $args);
27
+		if (!$output->toBool()) return $output;
28 28
 
29 29
 		$this->setMessage('success_updated');
30 30
 
Please login to merge, or discard this patch.
Braces   +3 added lines, -1 removed lines patch added patch discarded remove patch
@@ -24,7 +24,9 @@
 block discarded – undo
24 24
 		// Create a module Controller object
25 25
 		$oModuleController = getController('module');
26 26
 		$output = $oModuleController->insertModuleConfig('message',$args);
27
-		if(!$output->toBool()) return $output;
27
+		if(!$output->toBool()) {
28
+			return $output;
29
+		}
28 30
 
29 31
 		$this->setMessage('success_updated');
30 32
 
Please login to merge, or discard this patch.
modules/message/message.admin.model.php 2 patches
Braces   +1 added lines, -2 removed lines patch added patch discarded remove patch
@@ -11,8 +11,7 @@
 block discarded – undo
11 11
 		if(!$skin)
12 12
 		{
13 13
 			$tpl = '';
14
-		}
15
-		else
14
+		} else
16 15
 		{
17 16
 			$oModuleModel = getModel('module'); /* @var $oModuleModel moduleModel */
18 17
 			$skin_info = $oModuleModel->loadSkinInfo($this->module_path, $skin, $dir);
Please login to merge, or discard this patch.
Spacing   +2 added lines, -2 removed lines patch added patch discarded remove patch
@@ -1,6 +1,6 @@  discard block
 block discarded – undo
1 1
 <?php
2 2
 /* Copyright (C) NAVER <http://www.navercorp.com> */
3
-class messageAdminModel extends message{
3
+class messageAdminModel extends message {
4 4
 	public function getMessageAdminColorset()
5 5
 	{
6 6
 		$skin = Context::get('skin');
@@ -8,7 +8,7 @@  discard block
 block discarded – undo
8 8
 		Context::set('type', $type);
9 9
 		$dir = $type == 'P' ? 'skins' : 'm.skins';
10 10
 
11
-		if(!$skin)
11
+		if (!$skin)
12 12
 		{
13 13
 			$tpl = '';
14 14
 		}
Please login to merge, or discard this patch.
modules/message/message.mobile.php 2 patches
Braces   +9 added lines, -3 removed lines patch added patch discarded remove patch
@@ -18,8 +18,12 @@  discard block
 block discarded – undo
18 18
 		// Get configurations (using module model object)
19 19
 		$oModuleModel = getModel('module');
20 20
 		$config = $oModuleModel->getModuleConfig('message');
21
-		if(!is_object($config)) $config = new stdClass;
22
-		if(!$config->mskin) $config->mskin = 'default';
21
+		if(!is_object($config)) {
22
+			$config = new stdClass;
23
+		}
24
+		if(!$config->mskin) {
25
+			$config->mskin = 'default';
26
+		}
23 27
 		// Set the template path
24 28
 		$template_path = sprintf('%sm.skins/%s', $this->module_path, $config->mskin);
25 29
 		// Get the member configuration
@@ -30,7 +34,9 @@  discard block
 block discarded – undo
30 34
 		$ssl_mode = false;
31 35
 		if($member_config->enable_ssl == 'Y')
32 36
 		{
33
-			if(strncasecmp('https://', Context::getRequestUri(), 8) === 0) $ssl_mode = true;
37
+			if(strncasecmp('https://', Context::getRequestUri(), 8) === 0) {
38
+				$ssl_mode = true;
39
+			}
34 40
 		}
35 41
 		Context::set('ssl_mode',$ssl_mode);
36 42
 
Please login to merge, or discard this patch.
Spacing   +5 added lines, -5 removed lines patch added patch discarded remove patch
@@ -18,8 +18,8 @@  discard block
 block discarded – undo
18 18
 		// Get configurations (using module model object)
19 19
 		$oModuleModel = getModel('module');
20 20
 		$config = $oModuleModel->getModuleConfig('message');
21
-		if(!is_object($config)) $config = new stdClass;
22
-		if(!$config->mskin) $config->mskin = 'default';
21
+		if (!is_object($config)) $config = new stdClass;
22
+		if (!$config->mskin) $config->mskin = 'default';
23 23
 		// Set the template path
24 24
 		$template_path = sprintf('%sm.skins/%s', $this->module_path, $config->mskin);
25 25
 		// Get the member configuration
@@ -28,11 +28,11 @@  discard block
 block discarded – undo
28 28
 		Context::set('member_config', $member_config);
29 29
 		// Set a flag to check if the https connection is made when using SSL and create https url 
30 30
 		$ssl_mode = false;
31
-		if($member_config->enable_ssl == 'Y')
31
+		if ($member_config->enable_ssl == 'Y')
32 32
 		{
33
-			if(strncasecmp('https://', Context::getRequestUri(), 8) === 0) $ssl_mode = true;
33
+			if (strncasecmp('https://', Context::getRequestUri(), 8) === 0) $ssl_mode = true;
34 34
 		}
35
-		Context::set('ssl_mode',$ssl_mode);
35
+		Context::set('ssl_mode', $ssl_mode);
36 36
 
37 37
 		Context::set('system_message', nl2br($this->getMessage()));
38 38
 
Please login to merge, or discard this patch.
modules/message/message.view.php 2 patches
Spacing   +5 added lines, -5 removed lines patch added patch discarded remove patch
@@ -23,12 +23,12 @@  discard block
 block discarded – undo
23 23
 		$oModuleModel = getModel('module');
24 24
 		$this->module_config = $config = $oModuleModel->getModuleConfig('message', $this->module_info->site_srl);
25 25
 
26
-		if(!$config)
26
+		if (!$config)
27 27
 		{
28 28
 			$config = new stdClass();
29 29
 		}
30 30
 
31
-		if(!$config->skin)
31
+		if (!$config->skin)
32 32
 		{
33 33
 			$config->skin = 'xedition';
34 34
 			$template_path = sprintf('%sskins/%s', $this->module_path, $config->skin);
@@ -54,11 +54,11 @@  discard block
 block discarded – undo
54 54
 		Context::set('member_config', $member_config);
55 55
 		// Set a flag to check if the https connection is made when using SSL and create https url
56 56
 		$ssl_mode = false;
57
-		if($member_config->enable_ssl == 'Y')
57
+		if ($member_config->enable_ssl == 'Y')
58 58
 		{
59
-			if(strncasecmp('https://', Context::getRequestUri(), 8) === 0) $ssl_mode = true;
59
+			if (strncasecmp('https://', Context::getRequestUri(), 8) === 0) $ssl_mode = true;
60 60
 		}
61
-		Context::set('ssl_mode',$ssl_mode);
61
+		Context::set('ssl_mode', $ssl_mode);
62 62
 
63 63
 		Context::set('system_message', nl2br($this->getMessage()));
64 64
 
Please login to merge, or discard this patch.
Braces   +5 added lines, -5 removed lines patch added patch discarded remove patch
@@ -32,16 +32,14 @@  discard block
 block discarded – undo
32 32
 		{
33 33
 			$config->skin = 'xedition';
34 34
 			$template_path = sprintf('%sskins/%s', $this->module_path, $config->skin);
35
-		}
36
-		else
35
+		} else
37 36
 		{
38 37
 			//check theme
39 38
 			$config_parse = explode('|@|', $config->skin);
40 39
 			if (count($config_parse) > 1)
41 40
 			{
42 41
 				$template_path = sprintf('./themes/%s/modules/message/', $config_parse[0]);
43
-			}
44
-			else
42
+			} else
45 43
 			{
46 44
 				$template_path = sprintf('%sskins/%s', $this->module_path, $config->skin);
47 45
 			}
@@ -56,7 +54,9 @@  discard block
 block discarded – undo
56 54
 		$ssl_mode = false;
57 55
 		if($member_config->enable_ssl == 'Y')
58 56
 		{
59
-			if(strncasecmp('https://', Context::getRequestUri(), 8) === 0) $ssl_mode = true;
57
+			if(strncasecmp('https://', Context::getRequestUri(), 8) === 0) {
58
+				$ssl_mode = true;
59
+			}
60 60
 		}
61 61
 		Context::set('ssl_mode',$ssl_mode);
62 62
 
Please login to merge, or discard this patch.
modules/module/module.admin.view.php 2 patches
Braces   +16 added lines, -7 removed lines patch added patch discarded remove patch
@@ -121,8 +121,7 @@  discard block
 block discarded – undo
121 121
 			// Set a template file
122 122
 			$this->setTemplateFile('category_update_form');
123 123
 			// If not selected, display a list of categories
124
-		}
125
-		else
124
+		} else
126 125
 		{
127 126
 			$category_list = $oModuleModel->getModuleCategories();
128 127
 			Context::set('category_list', $category_list);
@@ -165,7 +164,9 @@  discard block
 block discarded – undo
165 164
 		$module_srls = Context::get('module_srls');
166 165
 
167 166
 		$modules = explode(',',$module_srls);
168
-		if(!count($modules)) if(!$module_srls) return new Object(-1,'msg_invalid_request');
167
+		if(!count($modules)) {
168
+			if(!$module_srls) return new Object(-1,'msg_invalid_request');
169
+		}
169 170
 
170 171
 		$oModuleModel = getModel('module');
171 172
 		$columnList = array('module_srl', 'module');
@@ -201,7 +202,9 @@  discard block
 block discarded – undo
201 202
 		$module_srls = Context::get('module_srls');
202 203
 
203 204
 		$modules = explode(',',$module_srls);
204
-		if(!count($modules)) if(!$module_srls) return new Object(-1,'msg_invalid_request');
205
+		if(!count($modules)) {
206
+			if(!$module_srls) return new Object(-1,'msg_invalid_request');
207
+		}
205 208
 		// pre-define variables because you can get contents from other module (call by reference)
206 209
 		$content = '';
207 210
 		// Call a trigger for additional settings
@@ -224,7 +227,9 @@  discard block
 block discarded – undo
224 227
 		$module_srls = Context::get('module_srls');
225 228
 
226 229
 		$modules = explode(',',$module_srls);
227
-		if(!count($modules)) if(!$module_srls) return new Object(-1,'msg_invalid_request');
230
+		if(!count($modules)) {
231
+			if(!$module_srls) return new Object(-1,'msg_invalid_request');
232
+		}
228 233
 
229 234
 		$oModuleModel = getModel('module');
230 235
 		$columnList = array('module_srl', 'module', 'site_srl');
@@ -238,8 +243,12 @@  discard block
 block discarded – undo
238 243
 		{
239 244
 			foreach($source_grant_list as $key => $val)
240 245
 			{
241
-				if(!$val->default) $val->default = 'guest';
242
-				if($val->default == 'root') $val->default = 'manager';
246
+				if(!$val->default) {
247
+					$val->default = 'guest';
248
+				}
249
+				if($val->default == 'root') {
250
+					$val->default = 'manager';
251
+				}
243 252
 				$grant_list->{$key} = $val;
244 253
 			}
245 254
 		}
Please login to merge, or discard this patch.
Spacing   +23 added lines, -23 removed lines patch added patch discarded remove patch
@@ -35,9 +35,9 @@  discard block
 block discarded – undo
35 35
 		$oAutoinstallModel = getModel('autoinstall');
36 36
 
37 37
 		$module_list = $oModuleModel->getModuleList();
38
-		if(is_array($module_list))
38
+		if (is_array($module_list))
39 39
 		{
40
-			foreach($module_list as $key => $val)
40
+			foreach ($module_list as $key => $val)
41 41
 			{
42 42
 				$module_list[$key]->delete_url = $oAutoinstallModel->getRemoveUrlByPath($val->path);
43 43
 
@@ -47,7 +47,7 @@  discard block
 block discarded – undo
47 47
 				$module_list[$key]->need_autoinstall_update = $package[$packageSrl]->need_update;
48 48
 
49 49
 				// get easyinstall update url
50
-				if($module_list[$key]->need_autoinstall_update == 'Y')
50
+				if ($module_list[$key]->need_autoinstall_update == 'Y')
51 51
 				{
52 52
 					$module_list[$key]->update_url = $oAutoinstallModel->getUpdateUrlByPackageSrl($packageSrl);
53 53
 				}
@@ -58,9 +58,9 @@  discard block
 block discarded – undo
58 58
 
59 59
 		$favoriteList = $output->get('favoriteList');
60 60
 		$favoriteModuleList = array();
61
-		if($favoriteList)
61
+		if ($favoriteList)
62 62
 		{
63
-			foreach($favoriteList as $favorite => $favorite_info)
63
+			foreach ($favoriteList as $favorite => $favorite_info)
64 64
 			{
65 65
 				$favoriteModuleList[] = $favorite_info->module;
66 66
 			}
@@ -110,9 +110,9 @@  discard block
 block discarded – undo
110 110
 		//Security
111 111
 		$security = new Security();
112 112
 
113
-		if($module_category_srl)
113
+		if ($module_category_srl)
114 114
 		{
115
-			$selected_category  = $oModuleModel->getModuleCategory($module_category_srl);
115
+			$selected_category = $oModuleModel->getModuleCategory($module_category_srl);
116 116
 			Context::set('selected_category', $selected_category);
117 117
 
118 118
 			//Security
@@ -164,15 +164,15 @@  discard block
 block discarded – undo
164 164
 	{
165 165
 		$module_srls = Context::get('module_srls');
166 166
 
167
-		$modules = explode(',',$module_srls);
168
-		if(!count($modules)) if(!$module_srls) return new Object(-1,'msg_invalid_request');
167
+		$modules = explode(',', $module_srls);
168
+		if (!count($modules)) if (!$module_srls) return new Object(-1, 'msg_invalid_request');
169 169
 
170 170
 		$oModuleModel = getModel('module');
171 171
 		$columnList = array('module_srl', 'module');
172 172
 		$module_info = $oModuleModel->getModuleInfoByModuleSrl($modules[0], $columnList);
173 173
 		// Get a skin list of the module
174
-		$skin_list = $oModuleModel->getSkins(_XE_PATH_ . 'modules/'.$module_info->module);
175
-		Context::set('skin_list',$skin_list);
174
+		$skin_list = $oModuleModel->getSkins(_XE_PATH_.'modules/'.$module_info->module);
175
+		Context::set('skin_list', $skin_list);
176 176
 		// Get a layout list
177 177
 		$oLayoutModel = getModel('layout');
178 178
 		$layout_list = $oLayoutModel->getLayoutList();
@@ -182,7 +182,7 @@  discard block
 block discarded – undo
182 182
 		Context::set('module_category', $module_category);
183 183
 
184 184
 		$security = new Security();
185
-		$security->encodeHTML('layout_list..title','layout_list..layout');
185
+		$security->encodeHTML('layout_list..title', 'layout_list..layout');
186 186
 		$security->encodeHTML('skin_list....');
187 187
 		$security->encodeHTML('module_category...');
188 188
 
@@ -200,8 +200,8 @@  discard block
 block discarded – undo
200 200
 	{
201 201
 		$module_srls = Context::get('module_srls');
202 202
 
203
-		$modules = explode(',',$module_srls);
204
-		if(!count($modules)) if(!$module_srls) return new Object(-1,'msg_invalid_request');
203
+		$modules = explode(',', $module_srls);
204
+		if (!count($modules)) if (!$module_srls) return new Object(-1, 'msg_invalid_request');
205 205
 		// pre-define variables because you can get contents from other module (call by reference)
206 206
 		$content = '';
207 207
 		// Call a trigger for additional settings
@@ -223,8 +223,8 @@  discard block
 block discarded – undo
223 223
 	{
224 224
 		$module_srls = Context::get('module_srls');
225 225
 
226
-		$modules = explode(',',$module_srls);
227
-		if(!count($modules)) if(!$module_srls) return new Object(-1,'msg_invalid_request');
226
+		$modules = explode(',', $module_srls);
227
+		if (!count($modules)) if (!$module_srls) return new Object(-1, 'msg_invalid_request');
228 228
 
229 229
 		$oModuleModel = getModel('module');
230 230
 		$columnList = array('module_srl', 'module', 'site_srl');
@@ -234,12 +234,12 @@  discard block
 block discarded – undo
234 234
 		// Grant virtual permissions for access and manager
235 235
 		$grant_list->access->title = Context::getLang('grant_access');
236 236
 		$grant_list->access->default = 'guest';
237
-		if(count($source_grant_list))
237
+		if (count($source_grant_list))
238 238
 		{
239
-			foreach($source_grant_list as $key => $val)
239
+			foreach ($source_grant_list as $key => $val)
240 240
 			{
241
-				if(!$val->default) $val->default = 'guest';
242
-				if($val->default == 'root') $val->default = 'manager';
241
+				if (!$val->default) $val->default = 'guest';
242
+				if ($val->default == 'root') $val->default = 'manager';
243 243
 				$grant_list->{$key} = $val;
244 244
 			}
245 245
 		}
@@ -268,7 +268,7 @@  discard block
 block discarded – undo
268 268
 		// Get the language file of the current site
269 269
 		$site_module_info = Context::get('site_module_info');
270 270
 		$args = new stdClass();
271
-		$args->site_srl = (int)$site_module_info->site_srl;
271
+		$args->site_srl = (int) $site_module_info->site_srl;
272 272
 		$args->langCode = Context::get('lang_type');
273 273
 		$args->page = Context::get('page'); // /< Page
274 274
 		$args->list_count = 30; // /< the number of posts to display on a single page
@@ -287,7 +287,7 @@  discard block
 block discarded – undo
287 287
 		Context::set('lang_code_list', $output->data);
288 288
 		Context::set('page_navigation', $output->page_navigation);
289 289
 
290
-		if(Context::get('module') != 'admin')
290
+		if (Context::get('module') != 'admin')
291 291
 		{
292 292
 			$this->setLayoutPath('./common/tpl');
293 293
 			$this->setLayoutFile('popup_layout');
@@ -301,7 +301,7 @@  discard block
 block discarded – undo
301 301
 		$oModuleModel = getModel('module');
302 302
 		$output = $oModuleModel->getModuleFileBoxList();
303 303
 		$page = Context::get('page');
304
-		$page = $page?$page:1;
304
+		$page = $page ? $page : 1;
305 305
 		Context::set('filebox_list', $output->data);
306 306
 		Context::set('page_navigation', $output->page_navigation);
307 307
 		Context::set('page', $page);
Please login to merge, or discard this patch.
modules/module/module.mobile.php 1 patch
Spacing   +1 added lines, -1 removed lines patch added patch discarded remove patch
@@ -4,7 +4,7 @@
 block discarded – undo
4 4
 {
5 5
 	function dispModuleChangeLang()
6 6
 	{
7
-		$this->setTemplatePath(sprintf("%stpl/",$this->module_path));
7
+		$this->setTemplatePath(sprintf("%stpl/", $this->module_path));
8 8
 		$this->setTemplateFile('lang.html');
9 9
 	}
10 10
 }
Please login to merge, or discard this patch.