Skip to content

Commit ad9418a

Browse files
committed
Revert "Fix fatal 'class already declared' errors when using external standards"
This reverts commit 7130abe.
1 parent 7130abe commit ad9418a

File tree

2 files changed

+3
-3
lines changed

2 files changed

+3
-3
lines changed

autoload.php

+2-2
Original file line numberDiff line numberDiff line change
@@ -76,7 +76,7 @@ public static function load($class)
7676
if (strpos(__DIR__, 'phar://') !== 0
7777
&& file_exists(__DIR__.'/../../autoload.php') === true
7878
) {
79-
self::$composerAutoloader = include_once __DIR__.'/../../autoload.php';
79+
self::$composerAutoloader = include __DIR__.'/../../autoload.php';
8080
if (self::$composerAutoloader instanceof \Composer\Autoload\ClassLoader) {
8181
self::$composerAutoloader->unregister();
8282
self::$composerAutoloader->register();
@@ -164,7 +164,7 @@ public static function loadFile($path)
164164
$interfaces = get_declared_interfaces();
165165
$traits = get_declared_traits();
166166

167-
include_once $path;
167+
include $path;
168168

169169
$className = null;
170170
$newClasses = array_reverse(array_diff(get_declared_classes(), $classes));

src/Runner.php

+1-1
Original file line numberDiff line numberDiff line change
@@ -313,7 +313,7 @@ private function run()
313313

314314
// Include bootstrap files.
315315
foreach ($this->config->bootstrap as $bootstrap) {
316-
include_once $bootstrap;
316+
include $bootstrap;
317317
}
318318

319319
if ($this->config->stdin === true) {

0 commit comments

Comments
 (0)