Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

__autoload is deprecated #769

Open
JimMackin opened this issue Apr 11, 2022 · 0 comments
Open

__autoload is deprecated #769

JimMackin opened this issue Apr 11, 2022 · 0 comments

Comments

@JimMackin
Copy link

Bug report

The __autoload function used in variants/variant.php is deprecated and due to be removed. Further it can cause issues if a part of the code requires the PHP Mailer library bundled with the codebase as this will unintentionally remove the autoloader.

Expected behaviour

Requiring the PHPMailer library should not impact variant code.

Actual behaviour

Requiring the PHP Mailer library breaks any calls to unloaded Variant classes

Steps to reproduce

require_once(l_r('objects/mailer.php')); in any core file could trigger this. For me requiring the mailer inobjects/members.php cause variants to break.

JimMackin added a commit to JimMackin/webDiplomacy that referenced this issue Apr 11, 2022
@JimMackin JimMackin changed the title __autoload is soon to be deprecated __autoload is deprecated Apr 11, 2022
JimMackin added a commit to JimMackin/webDiplomacy that referenced this issue Apr 11, 2022
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

1 participant