File tree Expand file tree Collapse file tree 2 files changed +14
-4
lines changed
HttpFoundation/Tests/Resources/stubs
Lock/Tests/Resources/stubs Expand file tree Collapse file tree 2 files changed +14
-4
lines changed Original file line number Diff line number Diff line change 11
11
12
12
namespace MongoDB ;
13
13
14
+ use Composer \InstalledVersions ;
14
15
use MongoDB \Driver \Manager ;
15
16
17
+ if (InstalledVersions::isInstalled ('mongodb/mongodb ' )) {
18
+ return ;
19
+ }
20
+
16
21
/*
17
22
* Stubs for the mongodb/mongodb library version ~1.16
18
23
*/
19
- if (!class_exists (Client::class)) {
24
+ if (!class_exists (Client::class, false )) {
20
25
abstract class Client
21
26
{
22
27
abstract public function getManager (): Manager ;
Original file line number Diff line number Diff line change 11
11
12
12
namespace MongoDB ;
13
13
14
+ use Composer \InstalledVersions ;
14
15
use MongoDB \Driver \Manager ;
15
16
17
+ if (InstalledVersions::isInstalled ('mongodb/mongodb ' )) {
18
+ return ;
19
+ }
20
+
16
21
/*
17
22
* Stubs for the mongodb/mongodb library version ~1.16
18
23
*/
19
- if (!class_exists (Client::class)) {
24
+ if (!class_exists (Client::class, false )) {
20
25
abstract class Client
21
26
{
22
27
abstract public function getManager (): Manager ;
23
28
}
24
29
}
25
30
26
- if (!class_exists (Database::class)) {
31
+ if (!class_exists (Database::class, false )) {
27
32
abstract class Database
28
33
{
29
34
abstract public function getManager (): Manager ;
@@ -32,7 +37,7 @@ abstract public function getDatabaseName(): string;
32
37
}
33
38
}
34
39
35
- if (!class_exists (Collection::class)) {
40
+ if (!class_exists (Collection::class, false )) {
36
41
abstract class Collection
37
42
{
38
43
abstract public function getManager (): Manager ;
You can’t perform that action at this time.
0 commit comments