Thanks to visit codestin.com
Credit goes to github.com

Skip to content

autoload.php may not load the proper functions.php depending on CWD #109

@randstring

Description

@randstring

Hello,

This is quite a great library and works flawlessly, but I noticed a minor issue, which might be related to the way I use it.

Instead of using composer, I've integrated a version of the library in my source and load it using
require_once('closure/autoload.php');

Now, autoload.php has require_once 'functions.php'; which depending on the caller script location (and thus working directory), sometimes tries to load another functions.php from my project, because it does not specify a location. Shouldn't this become require_once __DIR__.'/functions.php' to make sure the proper one is required? Or would this conflict with Composer or some other intended way of usage?

Thank you.

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions