Passed
Push — master ( 4d438a...3290e5 )
by Georgi
02:54
created
src/User/Access/AccessCore.php 1 patch
Spacing   +1 added lines, -1 removed lines patch added patch discarded remove patch
@@ -50,7 +50,7 @@
 block discarded – undo
50 50
 	public static function boot()
51 51
 	{
52 52
 		// allow Super Admin full access
53
-		Gate::after(function ($user, $ability) {
53
+		Gate::after(function($user, $ability) {
54 54
 			return $user->hasRole('Super Admin');
55 55
 		});
56 56
 	}
Please login to merge, or discard this patch.
src/Dashboard/Integration/DashboardNavMenu.php 1 patch
Spacing   +4 added lines, -4 removed lines patch added patch discarded remove patch
@@ -21,12 +21,12 @@
 block discarded – undo
21 21
 			];
22 22
 		}
23 23
 
24
-		return $ret? [
25
-				__('DASHBOARD') => count($ret) > 1? [
24
+		return $ret ? [
25
+				__('DASHBOARD') => count($ret) > 1 ? [
26 26
 						'access' => true,
27 27
 						'group' => $ret,
28 28
 						'weight' => -10000
29
-				]: array_merge(reset($ret), ['weight' => -10000]),
30
-		]: [];
29
+				] : array_merge(reset($ret), ['weight' => -10000]),
30
+		] : [];
31 31
 	}
32 32
 }
33 33
\ No newline at end of file
Please login to merge, or discard this patch.
src/User/Settings/Database/Models/UserSetting.php 2 patches
Spacing   +6 added lines, -6 removed lines patch added patch discarded remove patch
@@ -23,7 +23,7 @@  discard block
 block discarded – undo
23 23
 	}
24 24
 	
25 25
 	private static function cacheUserVariables() {
26
-		if(isset(self::$userVariables)) return;
26
+		if (isset(self::$userVariables)) return;
27 27
 
28 28
 		$userId = Auth::id();
29 29
 		
@@ -33,7 +33,7 @@  discard block
 block discarded – undo
33 33
 	}
34 34
 	
35 35
 	private static function cacheAdminVariables() {
36
-		if(isset(self::$adminVariables)) return;
36
+		if (isset(self::$adminVariables)) return;
37 37
 
38 38
 		foreach (self::where('user_id', 0) as $row) {
39 39
 			self::$adminVariables[$row['group']][$row['name']] = $row['value'];
@@ -41,7 +41,7 @@  discard block
 block discarded – undo
41 41
 	}
42 42
 	
43 43
 	public static function get($group, $name, $user = null) {
44
-		$user = $user?: Auth::id();
44
+		$user = $user ?: Auth::id();
45 45
 		
46 46
 		if (!$user || !is_numeric($user)) return;
47 47
 		
@@ -51,7 +51,7 @@  discard block
 block discarded – undo
51 51
 	}
52 52
 	
53 53
 	public static function getGroup($group, $user = null) {
54
-		$user = $user?: Auth::id();
54
+		$user = $user ?: Auth::id();
55 55
 		
56 56
 		if (!$user || !is_numeric($user)) return;
57 57
 		
@@ -73,7 +73,7 @@  discard block
 block discarded – undo
73 73
 	}
74 74
 	
75 75
 	public static function put($group, $name, $value, $user = null) {
76
-		$user_id = $user?: Auth::id();
76
+		$user_id = $user ?: Auth::id();
77 77
 		
78 78
 		if (!$user_id || !is_numeric($user_id)) return;
79 79
 		
@@ -101,7 +101,7 @@  discard block
 block discarded – undo
101 101
 	}
102 102
 	
103 103
 	public static function forget($group, $name, $user = null) {
104
-		$user_id = $user?: Auth::id();
104
+		$user_id = $user ?: Auth::id();
105 105
 		
106 106
 		if (!$user_id || !is_numeric($user_id)) return;
107 107
 		
Please login to merge, or discard this patch.
Braces   +18 added lines, -6 removed lines patch added patch discarded remove patch
@@ -23,7 +23,9 @@  discard block
 block discarded – undo
23 23
 	}
24 24
 	
25 25
 	private static function cacheUserVariables() {
26
-		if(isset(self::$userVariables)) return;
26
+		if(isset(self::$userVariables)) {
27
+			return;
28
+		}
27 29
 
28 30
 		$userId = Auth::id();
29 31
 		
@@ -33,7 +35,9 @@  discard block
 block discarded – undo
33 35
 	}
34 36
 	
35 37
 	private static function cacheAdminVariables() {
36
-		if(isset(self::$adminVariables)) return;
38
+		if(isset(self::$adminVariables)) {
39
+			return;
40
+		}
37 41
 
38 42
 		foreach (self::where('user_id', 0) as $row) {
39 43
 			self::$adminVariables[$row['group']][$row['name']] = $row['value'];
@@ -43,7 +47,9 @@  discard block
 block discarded – undo
43 47
 	public static function get($group, $name, $user = null) {
44 48
 		$user = $user?: Auth::id();
45 49
 		
46
-		if (!$user || !is_numeric($user)) return;
50
+		if (!$user || !is_numeric($user)) {
51
+			return;
52
+		}
47 53
 		
48 54
 		self::cache();
49 55
 		
@@ -53,7 +59,9 @@  discard block
 block discarded – undo
53 59
 	public static function getGroup($group, $user = null) {
54 60
 		$user = $user?: Auth::id();
55 61
 		
56
-		if (!$user || !is_numeric($user)) return;
62
+		if (!$user || !is_numeric($user)) {
63
+			return;
64
+		}
57 65
 		
58 66
 		self::cache();
59 67
 
@@ -75,7 +83,9 @@  discard block
 block discarded – undo
75 83
 	public static function put($group, $name, $value, $user = null) {
76 84
 		$user_id = $user?: Auth::id();
77 85
 		
78
-		if (!$user_id || !is_numeric($user_id)) return;
86
+		if (!$user_id || !is_numeric($user_id)) {
87
+			return;
88
+		}
79 89
 		
80 90
 		self::cache();
81 91
 
@@ -103,7 +113,9 @@  discard block
 block discarded – undo
103 113
 	public static function forget($group, $name, $user = null) {
104 114
 		$user_id = $user?: Auth::id();
105 115
 		
106
-		if (!$user_id || !is_numeric($user_id)) return;
116
+		if (!$user_id || !is_numeric($user_id)) {
117
+			return;
118
+		}
107 119
 		
108 120
 		self::cache();
109 121
 		
Please login to merge, or discard this patch.