Skip to content

Commit 1ea86d8

Browse files
committed
scan root for phpunit
1 parent 349219a commit 1ea86d8

File tree

5 files changed

+12
-6
lines changed

5 files changed

+12
-6
lines changed

CHANGELOG.md

Lines changed: 6 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -6,6 +6,12 @@ The format is based on [Keep a Changelog](https://keepachangelog.com/en/1.0.0/),
66
and this project adheres to [Semantic Versioning](https://semver.org/spec/v2.0.0.html).
77

88

9+
## [2.2.1] - 2022-08-01
10+
11+
### Improvements
12+
13+
- Scan root for phpunit folder
14+
915
## [2.2.0] - 2022-07-29
1016

1117
### Improvements

controllers/admin/AdminBlmVulnController.php

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -73,13 +73,13 @@ private function fixVulnerabilities()
7373
->scan()
7474
->fix();
7575

76-
(new RemoveDirectories(Config::VULNERABLE_ROOT_DIRECTORIES))
76+
(new RemoveDirectories([Config::ROOT_DIRECTORY]))
7777
->setDirectory(Config::VULNERABLE_DIRECTORY)
7878
->setRecursive(false)
7979
->scan()
8080
->fix();
8181

82-
(new RemoveDirectories(Config::VULNERABLE_ROOT_DIRECTORIES))
82+
(new RemoveDirectories(Config::VULNERABLE_DIRECTORIES))
8383
->setDirectory(Config::VULNERABLE_DIRECTORY)
8484
->setRecursive(true)
8585
->scan()

src/domain/service/scanner/FilePermissions.php

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -41,7 +41,7 @@ public function __construct(array $directories)
4141
$this->directories = $directories;
4242
}
4343

44-
public function setRoot($root): self {
44+
public function setRoot(string $root): self {
4545
$this->root = $root;
4646

4747
return $this;

src/resources/config/Config.php

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -233,7 +233,7 @@ final class Config
233233
*
234234
* @var string[]
235235
*/
236-
const VULNERABLE_ROOT_DIRECTORIES = [
236+
const VULNERABLE_DIRECTORIES = [
237237
_PS_MODULE_DIR_,
238238
_PS_ROOT_DIR_ . '/vendor/',
239239
];

src/web/form/ScannerForm.php

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -142,12 +142,12 @@ private function getInsecureFiles(): array
142142
private function getInsecurePackages(): array
143143
{
144144
return array_merge(
145-
(new RemoveDirectories(Config::VULNERABLE_ROOT_DIRECTORIES))
145+
(new RemoveDirectories([Config::ROOT_DIRECTORY]))
146146
->setDirectory(Config::VULNERABLE_DIRECTORY)
147147
->setRecursive(false)
148148
->scan()
149149
->dryRun(),
150-
(new RemoveDirectories(Config::VULNERABLE_ROOT_DIRECTORIES))
150+
(new RemoveDirectories(Config::VULNERABLE_DIRECTORIES))
151151
->setDirectory(Config::VULNERABLE_DIRECTORY)
152152
->setRecursive(true)
153153
->scan()

0 commit comments

Comments
 (0)