cedaro / satispress

Expose installed WordPress plugins and themes as Composer packages.
508 stars 51 forks source link

Fatal error for packages.json #56

Closed GaryJones closed 6 years ago

GaryJones commented 6 years ago

The current develop branch throws a fatal error when visiting the packages.json URL:

Fatal error: Uncaught Error: Call to undefined function SatisPress\Repository\get_plugins() in /app/public/wp-content/plugins/satispress/src/Repository/InstalledPlugins.php on line 51

screenshot 2018-07-08 11 54 34

bradyvercher commented 6 years ago

I'm not seeing this one. Would prepending a \ to that get_plugins() call fix this for you?

GaryJones commented 6 years ago

No, I tried that. I didn't have a chance to investigate further, but I wondered if the handling of the request was such that get_plugins() wasn't defined due to a WP file not loaded.

bradyvercher commented 6 years ago

That would make sense. I have a bunch of plugins running on my install, so one of them is bound to be loading the file that defines get_plugins().

It gets included a couple places in SatisPress, so I may just include it in the main plugin file instead.

GaryJones commented 6 years ago

I have a bunch of plugins running on my install, so one of them is bound to be loading the file that defines get_plugins().

My development install of SatisPress literally just has SatisPress and a couple of Twenty * themes installed, so the opposite of yours.

bradyvercher commented 6 years ago

Did c06db53 fix this for you?

GaryJones commented 6 years ago

Did c06db53 fix this for you?

The last develop branch has it all working, so I guess so!