Passed
Push — master ( 076f6b...c1ddd2 )
by Morris
15:36 queued 04:46
created
apps/user_ldap/lib/User/DeletedUsersIndex.php 1 patch
Spacing   +5 added lines, -5 removed lines patch added patch discarded remove patch
@@ -71,7 +71,7 @@  discard block
 block discarded – undo
71 71
 			'user_ldap', 'isDeleted', '1');
72 72
 
73 73
 		$userObjects = [];
74
-		foreach($deletedUsers as $user) {
74
+		foreach ($deletedUsers as $user) {
75 75
 			$userObjects[] = new OfflineUser($user, $this->config, $this->db, $this->mapping);
76 76
 		}
77 77
 		$this->deletedUsers = $userObjects;
@@ -84,7 +84,7 @@  discard block
 block discarded – undo
84 84
 	 * @return \OCA\User_LDAP\User\OfflineUser[]
85 85
 	 */
86 86
 	public function getUsers() {
87
-		if(is_array($this->deletedUsers)) {
87
+		if (is_array($this->deletedUsers)) {
88 88
 			return $this->deletedUsers;
89 89
 		}
90 90
 		return $this->fetchDeletedUsers();
@@ -95,7 +95,7 @@  discard block
 block discarded – undo
95 95
 	 * @return bool
96 96
 	 */
97 97
 	public function hasUsers() {
98
-		if(!is_array($this->deletedUsers)) {
98
+		if (!is_array($this->deletedUsers)) {
99 99
 			$this->fetchDeletedUsers();
100 100
 		}
101 101
 		return is_array($this->deletedUsers) && (count($this->deletedUsers) > 0);
@@ -109,12 +109,12 @@  discard block
 block discarded – undo
109 109
 	 */
110 110
 	public function markUser($ocName) {
111 111
 		$curValue = $this->config->getUserValue($ocName, 'user_ldap', 'isDeleted', '0');
112
-		if($curValue === '1') {
112
+		if ($curValue === '1') {
113 113
 			// the user is already marked, do not write to DB again
114 114
 			return;
115 115
 		}
116 116
 		$this->config->setUserValue($ocName, 'user_ldap', 'isDeleted', '1');
117
-		$this->config->setUserValue($ocName, 'user_ldap', 'foundDeleted', (string)time());
117
+		$this->config->setUserValue($ocName, 'user_ldap', 'foundDeleted', (string) time());
118 118
 		$this->deletedUsers = null;
119 119
 	}
120 120
 }
Please login to merge, or discard this patch.
apps/user_ldap/lib/User/OfflineUser.php 1 patch
Spacing   +5 added lines, -5 removed lines patch added patch discarded remove patch
@@ -171,7 +171,7 @@  discard block
 block discarded – undo
171 171
 	 * @return int
172 172
 	 */
173 173
 	public function getLastLogin() {
174
-		return (int)$this->lastLogin;
174
+		return (int) $this->lastLogin;
175 175
 	}
176 176
 
177 177
 	/**
@@ -179,7 +179,7 @@  discard block
 block discarded – undo
179 179
 	 * @return int
180 180
 	 */
181 181
 	public function getDetectedOn() {
182
-		return (int)$this->foundDeleted;
182
+		return (int) $this->foundDeleted;
183 183
 	}
184 184
 
185 185
 	/**
@@ -202,7 +202,7 @@  discard block
 block discarded – undo
202 202
 			'email'        => 'settings',
203 203
 			'lastLogin'    => 'login',
204 204
 		];
205
-		foreach($properties as $property => $app) {
205
+		foreach ($properties as $property => $app) {
206 206
 			$this->$property = $this->config->getUserValue($this->ocName, $app, $property, '');
207 207
 		}
208 208
 
@@ -225,7 +225,7 @@  discard block
 block discarded – undo
225 225
 		', 1);
226 226
 		$query->execute(array($this->ocName));
227 227
 		$sResult = $query->fetchColumn(0);
228
-		if((int)$sResult === 1) {
228
+		if ((int) $sResult === 1) {
229 229
 			$this->hasActiveShares = true;
230 230
 			return;
231 231
 		}
@@ -237,7 +237,7 @@  discard block
 block discarded – undo
237 237
 		', 1);
238 238
 		$query->execute(array($this->ocName));
239 239
 		$sResult = $query->fetchColumn(0);
240
-		if((int)$sResult === 1) {
240
+		if ((int) $sResult === 1) {
241 241
 			$this->hasActiveShares = true;
242 242
 			return;
243 243
 		}
Please login to merge, or discard this patch.
apps/user_ldap/lib/Command/ShowRemnants.php 1 patch
Spacing   +2 added lines, -2 removed lines patch added patch discarded remove patch
@@ -89,8 +89,8 @@
 block discarded – undo
89 89
 				'displayName' => $user->getDisplayName(),
90 90
 				'uid' => $user->getUID(),
91 91
 				'dn' => $user->getDN(),
92
-				'lastLogin' => $this->formatDate($user->getLastLogin(), '-', (bool)$input->getOption('short-date')),
93
-				'detectedOn' => $this->formatDate($user->getDetectedOn(), 'unknown', (bool)$input->getOption('short-date')),
92
+				'lastLogin' => $this->formatDate($user->getLastLogin(), '-', (bool) $input->getOption('short-date')),
93
+				'detectedOn' => $this->formatDate($user->getDetectedOn(), 'unknown', (bool) $input->getOption('short-date')),
94 94
 				'homePath' => $user->getHomePath(),
95 95
 				'sharer' => $user->getHasActiveShares() ? 'Y' : 'N',
96 96
 			];
Please login to merge, or discard this patch.