• Resolved melbreaker

    (@melbreaker)


    PHP Fatal error:  Call to a member function get() on a non-object in \wp-content\plugins\tablepress\classes\class-controller.php on line 90
    
    PHP Stack trace:
    
    PHP   1. {main}() \wp-cron.php:0
    
    PHP   2. do_action_ref_array() \wp-cron.php:117
    
    PHP   3. call_user_func_array:{\wp-includes\plugin.php:600}() \wp-includes\plugin.php:600
    
    PHP   4. update_eb() \wp-includes\plugin.php:600
    
    PHP   5. wp_insert_post() \wp-content\themes\custom\functions.php:822
    
    PHP   6. do_action() \wp-includes\post.php:3420
    
    PHP   7. call_user_func_array:{\wp-includes\plugin.php:524}() \wp-includes\plugin.php:524
    
    PHP   8. relevanssi_insert_edit() \wp-includes\plugin.php:524
    
    PHP   9. relevanssi_publish() \wp-content\plugins\relevanssi\lib\indexing.php:637
    
    PHP  10. relevanssi_index_doc() \wp-content\plugins\relevanssi\lib\indexing.php:613
    
    PHP  11. TablePress::load_controller() \wp-content\plugins\relevanssi\lib\indexing.php:354
    
    PHP  12. TablePress::load_class() \wp-content\plugins\tablepress\classes\class-tablepress.php:261
    
    PHP  13. TablePress_Frontend_Controller->__construct() \wp-content\plugins\tablepress\classes\class-tablepress.php:208
    
    PHP  14. TablePress_Controller->__construct() \wp-content\plugins\tablepress\controllers\controller-frontend.php:37
    
    PHP  15. TablePress_Controller->plugin_update_check() \wp-content\plugins\tablepress\classes\class-controller.php:70

    I got above errors when wp-cron is running. I set up wp-cron to triggered update_eb() function which will update post content. It works fine if I manually trigger update_eb() myself but not working with wp-cron. I use WordPress 4.6.1 with relevanssi 3.5.4 and TablePress 1.7

    • This topic was modified 9 years, 8 months ago by melbreaker.
Viewing 3 replies - 1 through 3 (of 3 total)
  • Plugin Author Tobias Bäthge

    (@tobiasbg)

    Hi,

    thanks for your question, and sorry for the trouble.

    It seems that some internally necessary objects are not populated. It might be necessary to add the PHP calls

    TablePress::$model_options = TablePress::load_model( 'options' );
    TablePress::$model_table = TablePress::load_model( 'table' );

    to the code somewhere.

    Regards,
    Tobias

    Thread Starter melbreaker

    (@melbreaker)

    I add those 2 lines in my update_eb() function and it works!

    Thank you Tobias.

    Plugin Author Tobias Bäthge

    (@tobiasbg)

    Hi,

    no problem, you are very welcome! 🙂 Good to hear that this helped!

    Best wishes,
    Tobias

    P.S.: In case you haven’t, please rate TablePress here in the plugin directory. Thanks!

Viewing 3 replies - 1 through 3 (of 3 total)

The topic ‘Error at wp_cron when using with Relevanssi’ is closed to new replies.