moiseh / wp-magic-crud

Magic admin CRUD generator for WordPress
28 stars 5 forks source link

Parse error when activated in WordPress 6.1 #2

Open Ezyweb-uk opened 1 year ago

Ezyweb-uk commented 1 year ago

PHP Parse error: syntax error, unexpected 'private' (T_PRIVATE), expecting variable (T_VARIABLE) in \wp-content\plugins\wp-magic-crud-master\src\WPMC\Action\ArrayActionsMapper.php on line 11

moiseh commented 1 year ago

It seems to be a PHP version issue This plugin at the moment only works with php >= 8.0

Ezyweb-uk commented 1 year ago

Yes, no error when running on Php 8.1.9

However I think there must be a menu missing. The only one I see is Tools > Scheduled Actions, and in there is a hook called psoft_cruds_sync_1 which says on the log column:

2022-11-18 10:01:17 +0000
action failed via WP Cron: Parent menu not found: psoft-manager
moiseh commented 1 year ago

Fixed it

https://github.com/moiseh/wp-magic-crud/commit/2f97ffbed5d992e8b30aa7d96f1a8c9e66e7e043#diff-afbf33acfeb9c98266b1d39d0fac0eb54996c87991c243d2a7ed2d7d59b0e5cbR104

Thanks