Support » Plugin: Rabo OmniKassa 2.0 for WooCommerce » Issue with the callback

  • Resolved johan13v

    (@johan13v)


    After a payment Omnikassa sends a callback to process the payment when the user does not proceed to the website. However, I get a 500 error because of it and the status is not changed.

    PHP Fatal error: Uncaught Error: Call to a member function get_status() on bool in /nas/content/live/sitename/wp-content/plugins/woo-rabo-omnikassa/controllers/icwoorok2-controller.php:256

    After some digging I got to this error when I try to do it manually in functions.php, like this:

    $oOrder = wc_get_order(1154);
    $oOrder->getStatus();

    PHP Fatal error: Uncaught Error: Call to undefined method Automattic\\WooCommerce\\Admin\\Overrides\\Order::getStatus()

    Any ideas how to fix it?

    Wordpress 5.6
    Woocommerce 4.9.2
    iDEAL-Checkout (native) – Rabo OmniKassa 2.0 for WooCommerce 2.1.1

Viewing 2 replies - 1 through 2 (of 2 total)
  • Thread Starter johan13v

    (@johan13v)

    Hmm update to Woocommerce 5.0.0 fixed the problem.

    • This reply was modified 1 year, 7 months ago by johan13v.
    Plugin Author CodeBrain BV

    (@codebrainbv)

    The error shouldnt occur on versions before 5.0 either, we shall look into it just to make sure. The check is made to prevent already paid orders or completed orders to revert back.

    The problem was that the order object couldnt be loaded with ID 1154, and the function returned a false most likely.

    However the second error was generated because the getStatus() doesnt exist.

    • This reply was modified 1 year, 7 months ago by CodeBrain BV. Reason: Fixed a typo
Viewing 2 replies - 1 through 2 (of 2 total)
  • The topic ‘Issue with the callback’ is closed to new replies.