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

Loading Kirki via composer messes with other plugins/classes #2503

Open
JiveDig opened this issue Apr 6, 2023 · 0 comments
Open

Loading Kirki via composer messes with other plugins/classes #2503

JiveDig opened this issue Apr 6, 2023 · 0 comments

Comments

@JiveDig
Copy link

JiveDig commented Apr 6, 2023

Issue description:

When Kirki is loaded via composer (autoload.php) it causes clashes with other plugins, in a very strange way.

Version used:

4.1.0

Using theme_mods or options?

Neither, it happens when you load Kirki itself.

PHP error messages that might be related

Class 'Tutor\Models\CourseModel' not found

Via: https://wordpress.org/plugins/tutor/ on the Dashboard.

Class 'Smartcrawl_Vendor\Vanderlee\Syllable\Syllable' not found

via: https://wordpress.org/plugins/smartcrawl-seo/ when editing any post/page.

It happens with various other plugins as well, and doesn't happen when Kirki is not included.

Code to reproduce the issue (config + field(s))

I created a blank plugin, and installed Kirki via packagist via:

composer require kirki-framework/kirki

Then, the only line of code in the plugin is:

require_once __DIR__ . '/vendor/autoload.php';

When some plugins like Smartcrawl SEO, Tutor LMS, and others are loaded, it throws class not found errors, even though the class/file is definitely there. Commenting out the require_once line makes the error go away.

Another dev/friend said it has to do with how Kirki is using include-path, but I have yet to pinpoint the exact source of the issue.

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