Skip to content

Conversation

@nicolas-grekas
Copy link
Member

Q A
Branch? 4.4
Bug fix? no
New feature? no
BC breaks? no
Deprecations? no
Tests pass? yes
Fixed tickets -
License MIT
Doc PR -

On second look, I think this works :)

use Symfony\Component\DependencyInjection\Dumper\Preloader;
require dirname(__DIR__, 3).'/vendor/autoload.php';
require $autoloadFile;
Copy link
Member Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

now with proper detection of autoload.php location

Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Do we have any test covering the dumping of this file ?

Copy link
Member Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

yes; not precisely this line but the $classes[] = ... one below

nicolas-grekas added a commit that referenced this pull request Sep 10, 2019
This PR was merged into the 4.4 branch.

Discussion
----------

[DI] use dirname() when possible

| Q             | A
| ------------- | ---
| Branch?       | 4.4
| Bug fix?      | no
| New feature?  | no
| BC breaks?    | no
| Deprecations? | no
| Tests pass?   | yes
| Fixed tickets | -
| License       | MIT
| Doc PR        | -

On second look, I think this works :)

Commits
-------

2eae300 [DI] use dirname() when possible
@nicolas-grekas nicolas-grekas merged commit 2eae300 into symfony:4.4 Sep 10, 2019
@nicolas-grekas nicolas-grekas deleted the di-dirname branch September 10, 2019 13:36
@nicolas-grekas nicolas-grekas modified the milestones: next, 4.4 Oct 27, 2019
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Projects

None yet

Development

Successfully merging this pull request may close these issues.

4 participants