Skip to content

Commit

Permalink
chore: composer run cs:fix
Browse files Browse the repository at this point in the history
Signed-off-by: DorraJaouad <dorra.jaoued7@gmail.com>
  • Loading branch information
DorraJaouad committed Oct 13, 2024
1 parent 0f2185f commit ecb49b5
Show file tree
Hide file tree
Showing 2 changed files with 3 additions and 3 deletions.
4 changes: 2 additions & 2 deletions lib/Controller/IPWhitelistController.php
Original file line number Diff line number Diff line change
Expand Up @@ -93,7 +93,7 @@ public function add(string $ip, int $mask): JSONResponse {
$id++;

$value = $ip . '/' . $mask;
$this->config->setAppValue('bruteForce', 'whitelist_'.$id, $value);
$this->config->setAppValue('bruteForce', 'whitelist_' . $id, $value);
return new JSONResponse([
'id' => $id,
'ip' => $ip,
Expand All @@ -106,7 +106,7 @@ public function add(string $ip, int $mask): JSONResponse {
* @return JSONResponse
*/
public function remove(int $id): JSONResponse {
$this->config->deleteAppValue('bruteForce', 'whitelist_'.$id);
$this->config->deleteAppValue('bruteForce', 'whitelist_' . $id);

return new JSONResponse([]);
}
Expand Down
2 changes: 1 addition & 1 deletion tests/Controller/IPWhitelistControllerTest.php
Original file line number Diff line number Diff line change
Expand Up @@ -111,7 +111,7 @@ public function testAdd($ip, $mask, $valid) {
->with(
$this->equalTo('bruteForce'),
$this->equalTo('whitelist_100'),
$this->equalTo($ip.'/'.$mask)
$this->equalTo($ip . '/' . $mask)
);

$expected = new JSONResponse([
Expand Down

0 comments on commit ecb49b5

Please sign in to comment.