Skip to content
This repository was archived by the owner on Jul 24, 2023. It is now read-only.

Commit ff97b61

Browse files
committed
Merge pull request #111 from Adldap2/analysis-8b0a2a
Applied fixes from StyleCI
2 parents 51f4ca4 + 73d1fd2 commit ff97b61

File tree

3 files changed

+10
-10
lines changed

3 files changed

+10
-10
lines changed

src/AdldapAuthUserProvider.php

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -144,7 +144,7 @@ protected function authenticate($username, $password)
144144
protected function authenticateWithCredentials(array $credentials = [])
145145
{
146146
$username = $this->getUsernameFromCredentials($credentials);
147-
147+
148148
// Make sure we're connected to our LDAP server before we run any operations.
149149
if ($this->isConnected() && !empty($username)) {
150150
// Due to having the ability of choosing which attribute we login users

src/Traits/ImportsUsers.php

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -249,7 +249,7 @@ protected function getAdldap($provider = null)
249249
protected function getUsernameFromAdUser(User $user)
250250
{
251251
$username = $user->{$this->getLoginAttribute()};
252-
252+
253253
if (is_array($username)) {
254254
// We'll make sure we retrieve the users first username
255255
// attribute if it's contained in an array.

tests/AdldapTest.php

Lines changed: 8 additions & 8 deletions
Original file line numberDiff line numberDiff line change
@@ -2,11 +2,11 @@
22

33
namespace Adldap\Laravel\Tests;
44

5-
use Adldap\Models\User;
65
use Adldap\Connections\Ldap;
76
use Adldap\Contracts\AdldapInterface;
87
use Adldap\Laravel\Facades\Adldap;
98
use Adldap\Laravel\Tests\Models\User as EloquentUser;
9+
use Adldap\Models\User;
1010
use Illuminate\Support\Facades\App;
1111
use Illuminate\Support\Facades\Auth;
1212
use Illuminate\Support\Facades\Hash;
@@ -40,8 +40,8 @@ public function test_auth_passes($credentials = null)
4040
$credentials = $credentials ?: ['email' => '[email protected]', 'password' => '12345'];
4141

4242
$user = $this->getMockUser([
43-
'cn' => '',
44-
'mail' => '[email protected]',
43+
'cn' => '',
44+
'mail' => '[email protected]',
4545
'samaccountname' => 'jdoe',
4646
]);
4747

@@ -90,8 +90,8 @@ public function test_auth_passes_without_persistent_adldap_user()
9090
public function test_auth_fails_when_user_found()
9191
{
9292
$user = $this->getMockUser([
93-
'cn' => '',
94-
'mail' => '[email protected]',
93+
'cn' => '',
94+
'mail' => '[email protected]',
9595
'samaccountname' => 'jdoe',
9696
]);
9797

@@ -229,8 +229,8 @@ public function test_config_password_sync_disabled()
229229
$this->app['config']->set('adldap_auth.password_sync', false);
230230

231231
$user = $this->getMockUser([
232-
'cn' => '',
233-
'mail' => '[email protected]',
232+
'cn' => '',
233+
'mail' => '[email protected]',
234234
'samaccountname' => 'jdoe',
235235
]);
236236

@@ -258,7 +258,7 @@ public function test_config_password_sync_disabled()
258258
$this->assertTrue(Auth::attempt(compact('email', 'password')));
259259

260260
$user = Auth::user();
261-
261+
262262
// This check will fail due to password synchronization being disabled.
263263
$this->assertFalse(Hash::check($password, $user->password));
264264
}

0 commit comments

Comments
 (0)