Passed
Branch 0.4.0 (434eea)
by Anton
04:47
created
www/engine/System/Classes/Modules/Profile/Handler/Edit.php 2 patches
Spacing   +1 added lines, -1 removed lines patch added patch discarded remove patch
@@ -45,7 +45,7 @@
 block discarded – undo
45 45
 
46 46
 			if ($this->form_personal->handle($controller_personal) || $this->form_password->handle($controller_password)) {
47 47
 
48
-				Request::redirect(INSTALL_PATH . '/profile/edit?submitted');
48
+				Request::redirect(INSTALL_PATH.'/profile/edit?submitted');
49 49
 			}
50 50
 
51 51
 			# Display success message
Please login to merge, or discard this patch.
Braces   +3 added lines, -1 removed lines patch added patch discarded remove patch
@@ -50,7 +50,9 @@
 block discarded – undo
50 50
 
51 51
 			# Display success message
52 52
 
53
-			if (false !== Request::get('submitted')) Messages::set('success', Language::get('USER_SUCCESS_EDIT'));
53
+			if (false !== Request::get('submitted')) {
54
+				Messages::set('success', Language::get('USER_SUCCESS_EDIT'));
55
+			}
54 56
 
55 57
 			# ------------------------
56 58
 
Please login to merge, or discard this patch.
www/engine/System/Classes/Modules/Install/Handler/Database.php 1 patch
Spacing   +1 added lines, -1 removed lines patch added patch discarded remove patch
@@ -35,7 +35,7 @@
 block discarded – undo
35 35
 
36 36
 			if ($this->form->handle(new Install\Controller\Database())) {
37 37
 
38
-				Request::redirect(INSTALL_PATH . '/admin/register');
38
+				Request::redirect(INSTALL_PATH.'/admin/register');
39 39
 			}
40 40
 
41 41
 			# ------------------------
Please login to merge, or discard this patch.
www/engine/System/Classes/Modules/Install/Handler/Check.php 2 patches
Spacing   +1 added lines, -1 removed lines patch added patch discarded remove patch
@@ -18,7 +18,7 @@
 block discarded – undo
18 18
 
19 19
 				$class = ($value ? 'positive' : 'negative'); $icon = ($value ? 'check circle' : 'warning circle');
20 20
 
21
-				$text = Language::get('INSTALL_REQUIREMENT_' . strtoupper($name) . '_' . ($value ? 'SUCCESS' : 'FAIL'));
21
+				$text = Language::get('INSTALL_REQUIREMENT_'.strtoupper($name).'_'.($value ? 'SUCCESS' : 'FAIL'));
22 22
 
23 23
 				$requirements[] = ['class' => $class, 'icon' => $icon, 'text' => $text];
24 24
 			}
Please login to merge, or discard this patch.
Unused Use Statements   +5 added lines, -1 removed lines patch added patch discarded remove patch
@@ -2,7 +2,11 @@
 block discarded – undo
2 2
 
3 3
 namespace Modules\Install\Handler {
4 4
 
5
-	use Frames, Modules\Extend, Modules\Install, Utils\View, Language;
5
+	use Frames;
6
+	use Modules\Extend;
7
+	use Modules\Install;
8
+	use Utils\View;
9
+	use Language;
6 10
 
7 11
 	class Check extends Frames\Admin\Area\Install {
8 12
 
Please login to merge, or discard this patch.
www/engine/System/Classes/Modules/Entitizer/Controller/User.php 2 patches
Unused Use Statements   +3 added lines, -1 removed lines patch added patch discarded remove patch
@@ -2,7 +2,9 @@
 block discarded – undo
2 2
 
3 3
 namespace Modules\Entitizer\Controller {
4 4
 
5
-	use Modules\Entitizer, Utils\Validate, Str;
5
+	use Modules\Entitizer;
6
+	use Utils\Validate;
7
+	use Str;
6 8
 
7 9
 	class User {
8 10
 
Please login to merge, or discard this patch.
Braces   +27 added lines, -9 removed lines patch added patch discarded remove patch
@@ -31,30 +31,46 @@  discard block
 block discarded – undo
31 31
 
32 32
 			# Validate name & email
33 33
 
34
-			if (false === ($name = Validate::userName($name))) return ['name', 'USER_ERROR_NAME_INVALID'];
34
+			if (false === ($name = Validate::userName($name))) {
35
+				return ['name', 'USER_ERROR_NAME_INVALID'];
36
+			}
35 37
 
36
-			if (false === ($email = Validate::userEmail($email))) return ['email', 'USER_ERROR_EMAIL_INVALID'];
38
+			if (false === ($email = Validate::userEmail($email))) {
39
+				return ['email', 'USER_ERROR_EMAIL_INVALID'];
40
+			}
37 41
 
38 42
 			# Validate password
39 43
 
40 44
 			if ((0 === $this->user->id) || ('' !== $password)) {
41 45
 
42
-				if (false === ($password = Validate::userPassword($password))) return ['password', 'USER_ERROR_PASSWORD_INVALID'];
46
+				if (false === ($password = Validate::userPassword($password))) {
47
+					return ['password', 'USER_ERROR_PASSWORD_INVALID'];
48
+				}
43 49
 
44
-				if (0 !== strcmp($password, $password_retype)) return ['password_retype', 'USER_ERROR_PASSWORD_MISMATCH'];
50
+				if (0 !== strcmp($password, $password_retype)) {
51
+					return ['password_retype', 'USER_ERROR_PASSWORD_MISMATCH'];
52
+				}
45 53
 			}
46 54
 
47 55
 			# Check name exists
48 56
 
49
-			if (false === ($check_name = $this->user->check($name, 'name'))) return 'USER_ERROR_MODIFY';
57
+			if (false === ($check_name = $this->user->check($name, 'name'))) {
58
+				return 'USER_ERROR_MODIFY';
59
+			}
50 60
 
51
-			if ($check_name === 1) return ['name', 'USER_ERROR_NAME_DUPLICATE'];
61
+			if ($check_name === 1) {
62
+				return ['name', 'USER_ERROR_NAME_DUPLICATE'];
63
+			}
52 64
 
53 65
 			# Check email exists
54 66
 
55
-			if (false === ($check_email = $this->user->check($email, 'email'))) return 'USER_ERROR_MODIFY';
67
+			if (false === ($check_email = $this->user->check($email, 'email'))) {
68
+				return 'USER_ERROR_MODIFY';
69
+			}
56 70
 
57
-			if ($check_email === 1) return ['email', 'USER_ERROR_EMAIL_DUPLICATE'];
71
+			if ($check_email === 1) {
72
+				return ['email', 'USER_ERROR_EMAIL_DUPLICATE'];
73
+			}
58 74
 
59 75
 			# Modify user
60 76
 
@@ -84,7 +100,9 @@  discard block
 block discarded – undo
84 100
 
85 101
 			$modifier = ((0 === $this->user->id) ? 'create' : 'edit');
86 102
 
87
-			if (!$this->user->$modifier($data)) return 'USER_ERROR_MODIFY';
103
+			if (!$this->user->$modifier($data)) {
104
+				return 'USER_ERROR_MODIFY';
105
+			}
88 106
 
89 107
 			# ------------------------
90 108
 
Please login to merge, or discard this patch.
www/engine/System/Classes/Modules/Entitizer/Form/Page.php 1 patch
Unused Use Statements   +3 added lines, -1 removed lines patch added patch discarded remove patch
@@ -2,7 +2,9 @@
 block discarded – undo
2 2
 
3 3
 namespace Modules\Entitizer\Form {
4 4
 
5
-	use Modules\Entitizer, Utils\Form, Utils\Range;
5
+	use Modules\Entitizer;
6
+	use Utils\Form;
7
+	use Utils\Range;
6 8
 
7 9
 	class Page extends Form {
8 10
 
Please login to merge, or discard this patch.
www/engine/System/Classes/Modules/Entitizer/Form/User.php 1 patch
Unused Use Statements   +7 added lines, -1 removed lines patch added patch discarded remove patch
@@ -2,7 +2,13 @@
 block discarded – undo
2 2
 
3 3
 namespace Modules\Entitizer\Form {
4 4
 
5
-	use Modules\Auth, Modules\Entitizer, Utils\Form, Utils\Range, Geo\Country, Geo\Timezone, Language;
5
+	use Modules\Auth;
6
+	use Modules\Entitizer;
7
+	use Utils\Form;
8
+	use Utils\Range;
9
+	use Geo\Country;
10
+	use Geo\Timezone;
11
+	use Language;
6 12
 
7 13
 	class User extends Form {
8 14
 
Please login to merge, or discard this patch.
www/engine/System/Classes/Modules/Entitizer/Lister/Menuitems.php 2 patches
Unused Use Statements   +2 added lines, -1 removed lines patch added patch discarded remove patch
@@ -2,7 +2,8 @@
 block discarded – undo
2 2
 
3 3
 namespace Modules\Entitizer\Listview {
4 4
 
5
-	use Modules\Entitizer, Template;
5
+	use Modules\Entitizer;
6
+	use Template;
6 7
 
7 8
 	class Variables extends Entitizer\Utils\Listview {
8 9
 
Please login to merge, or discard this patch.
Braces   +3 added lines, -3 removed lines patch added patch discarded remove patch
@@ -30,9 +30,9 @@
 block discarded – undo
30 30
 
31 31
 		protected function processEntityParent(Template\Block $parent) {
32 32
 
33
-			if (0 !== $this->parent->id) $parent->getBlock('browse')->link = $this->parent->link;
34
-
35
-			else { $parent->getBlock('browse')->disable(); $parent->getBlock('browse_disabled')->enable(); }
33
+			if (0 !== $this->parent->id) {
34
+				$parent->getBlock('browse')->link = $this->parent->link;
35
+			} else { $parent->getBlock('browse')->disable(); $parent->getBlock('browse_disabled')->enable(); }
36 36
 		}
37 37
 
38 38
 		# Add item additional data
Please login to merge, or discard this patch.
www/engine/System/Classes/Modules/Entitizer/Lister/Pages.php 2 patches
Unused Use Statements   +3 added lines, -1 removed lines patch added patch discarded remove patch
@@ -2,7 +2,9 @@
 block discarded – undo
2 2
 
3 3
 namespace Modules\Entitizer\Lister {
4 4
 
5
-	use Modules\Entitizer, Utils\Range, Template;
5
+	use Modules\Entitizer;
6
+	use Utils\Range;
7
+	use Template;
6 8
 
7 9
 	class Pages extends Entitizer\Utils\Lister {
8 10
 
Please login to merge, or discard this patch.
Braces   +3 added lines, -3 removed lines patch added patch discarded remove patch
@@ -30,9 +30,9 @@
 block discarded – undo
30 30
 
31 31
 		protected function processEntityParent(Template\Block $parent) {
32 32
 
33
-			if ((0 !== $this->parent->id) && $this->parent->active) $parent->getBlock('browse')->link = $this->parent->link;
34
-
35
-			else { $parent->getBlock('browse')->disable(); $parent->getBlock('browse_disabled')->enable(); }
33
+			if ((0 !== $this->parent->id) && $this->parent->active) {
34
+				$parent->getBlock('browse')->link = $this->parent->link;
35
+			} else { $parent->getBlock('browse')->disable(); $parent->getBlock('browse_disabled')->enable(); }
36 36
 		}
37 37
 
38 38
 		# Add item additional data
Please login to merge, or discard this patch.
www/engine/System/Classes/Modules/Entitizer/Lister/Users.php 2 patches
Unused Use Statements   +4 added lines, -1 removed lines patch added patch discarded remove patch
@@ -2,7 +2,10 @@
 block discarded – undo
2 2
 
3 3
 namespace Modules\Entitizer\Lister {
4 4
 
5
-	use Modules\Auth, Modules\Entitizer, Utils\Range, Template;
5
+	use Modules\Auth;
6
+	use Modules\Entitizer;
7
+	use Utils\Range;
8
+	use Template;
6 9
 
7 10
 	class Users extends Entitizer\Utils\Lister {
8 11
 
Please login to merge, or discard this patch.
Braces   +3 added lines, -1 removed lines patch added patch discarded remove patch
@@ -40,7 +40,9 @@
 block discarded – undo
40 40
 
41 41
 			# Set remove button
42 42
 
43
-			if ($user->id === Auth::user()->id) $view->getBlock('remove')->class = 'disabled';
43
+			if ($user->id === Auth::user()->id) {
44
+				$view->getBlock('remove')->class = 'disabled';
45
+			}
44 46
 		}
45 47
 	}
46 48
 }
Please login to merge, or discard this patch.