Skip to content

Commit 5725af3

Browse files
author
Oliver Klee
authoredDec 5, 2019
[CLEANUP] Fix a warning with newer PHPMD versions (#125)
1 parent 30c05be commit 5725af3

File tree

1 file changed

+4
-4
lines changed

1 file changed

+4
-4
lines changed
 

‎src/Controller/SessionController.php

+4-4
Original file line numberDiff line numberDiff line change
@@ -35,7 +35,7 @@ class SessionController extends FOSRestController implements ClassResourceInterf
3535
/**
3636
* @var AdministratorTokenRepository
3737
*/
38-
private $administratorTokenRepository = null;
38+
private $tokenRepository = null;
3939

4040
/**
4141
* @param Authentication $authentication
@@ -49,7 +49,7 @@ public function __construct(
4949
) {
5050
$this->authentication = $authentication;
5151
$this->administratorRepository = $administratorRepository;
52-
$this->administratorTokenRepository = $tokenRepository;
52+
$this->tokenRepository = $tokenRepository;
5353
}
5454

5555
/**
@@ -96,7 +96,7 @@ public function deleteAction(Request $request, AdministratorToken $token): View
9696
throw new AccessDeniedHttpException('You do not have access to this session.', null, 1519831644);
9797
}
9898

99-
$this->administratorTokenRepository->remove($token);
99+
$this->tokenRepository->remove($token);
100100

101101
return View::create();
102102
}
@@ -131,7 +131,7 @@ private function createAndPersistToken(Administrator $administrator): Administra
131131
$token->setAdministrator($administrator);
132132
$token->generateExpiry();
133133
$token->generateKey();
134-
$this->administratorTokenRepository->save($token);
134+
$this->tokenRepository->save($token);
135135

136136
return $token;
137137
}

0 commit comments

Comments
 (0)
Please sign in to comment.