Title: Fatal Error causing issues
Last modified: November 20, 2020

---

# Fatal Error causing issues

 *  Resolved [smys123](https://wordpress.org/support/users/smys123/)
 * (@smys123)
 * [5 years, 4 months ago](https://wordpress.org/support/topic/fatal-error-causing-issues/)
 * This is happening at checkout.
 * 2020-11-19T00:04:04+00:00 CRITICAL Uncaught Error: Call to a member function 
   __unset() on null in /nas/content/live/petwantsfranch/wp-content/plugins/order-
   tip-woo/frontend/controllers/main.class.php:124
    Stack trace: #0 /nas/content/
   live/petwantsfranch/wp-includes/class-wp-hook.php(289): WOO_Order_Tip_Main->remove_tip_on_order_placed(
   43765) #1 /nas/content/live/petwantsfranch/wp-includes/class-wp-hook.php(311):
   WP_Hook->apply_filters(”, Array) #2 /nas/content/live/petwantsfranch/wp-includes/
   plugin.php(478): WP_Hook->do_action(Array) #3 /nas/content/live/petwantsfranch/
   wp-content/plugins/woocommerce/includes/data-stores/class-wc-order-data-store-
   cpt.php(88): do_action(‘woocommerce_new…’, 43765, Object(WC_Order)) #4 /nas/content/
   live/petwantsfranch/wp-content/plugins/woocommerce/includes/class-wc-data-store.
   php(169): WC_Order_Data_Store_CPT->create(Object(WC_Order)) #5 /nas/content/live/
   petwantsfranch/wp-content/plugins/woocommerce/includes/abstracts/abstract-wc-
   order.php(185): WC_Data_Store->create(Object(WC_Order)) #6 /nas/content/live/
   petw in /nas/content/live/petwantsfranch/wp-content/plugins/order-tip-woo/frontend/
   controllers/main.class.php on line 124
 * The page I need help with: _[[log in](https://login.wordpress.org/?redirect_to=https%3A%2F%2Fwordpress.org%2Fsupport%2Ftopic%2Ffatal-error-causing-issues%2F%3Foutput_format%3Dmd&locale=en_US)
   to see the link]_

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

 *  Plugin Author [railmedia](https://wordpress.org/support/users/railmedia/)
 * (@railmedia)
 * [5 years, 4 months ago](https://wordpress.org/support/topic/fatal-error-causing-issues/#post-13691941)
 * Hi there smys123,
 * Thanks for reporting this. I’ll look into the issue and get back to you with 
   a solution.
 * Best regards,
    Adrian
 *  Plugin Author [railmedia](https://wordpress.org/support/users/railmedia/)
 * (@railmedia)
 * [5 years, 4 months ago](https://wordpress.org/support/topic/fatal-error-causing-issues/#post-13692170)
 * Dear smys123,
 * If you can, please replace the entire function remove_tip_on_order_placed from
   the file /wp-content/plugins/order-tip-woo/frontend/controllers/main.class.php(
   line 120) with the following:
 *     ```
       function remove_tip_on_order_placed( $orderid ) {
   
            if( $this->settings['wc_order_tip_remove_new_order'] ) {
                $wc_session = WC()->session;
                $tip_is_set = $wc_session->get( 'tip' );
                if( $tip_is_set ) {
                    $wc_session->__unset( 'tip' );
                }
            }
   
        }
       ```
   
 * I will include this fix in the next release.
 * Please let me know how it went.
 * Regards,
    Adrian
 *  Thread Starter [smys123](https://wordpress.org/support/users/smys123/)
 * (@smys123)
 * [5 years, 4 months ago](https://wordpress.org/support/topic/fatal-error-causing-issues/#post-13692598)
 * Thanks Adrian,
 * I have implemented the change as requested.
 * I will have the owner place a subscription order to test.
 * Stand by.
 * Thanks!
    aaron
 *  Thread Starter [smys123](https://wordpress.org/support/users/smys123/)
 * (@smys123)
 * [5 years, 4 months ago](https://wordpress.org/support/topic/fatal-error-causing-issues/#post-13703266)
 * New set of errors:
 * 2020-11-24T00:03:04+00:00 CRITICAL Uncaught Error: Call to a member function 
   get() on null in /nas/content/live/petwantsfranch/wp-content/plugins/order-tip-
   woo/frontend/controllers/main.class.php:124
    Stack trace: #0 /nas/content/live/
   petwantsfranch/wp-includes/class-wp-hook.php(289): WOO_Order_Tip_Main->remove_tip_on_order_placed(
   43819) #1 /nas/content/live/petwantsfranch/wp-includes/class-wp-hook.php(311):
   WP_Hook->apply_filters(”, Array) #2 /nas/content/live/petwantsfranch/wp-includes/
   plugin.php(478): WP_Hook->do_action(Array) #3 /nas/content/live/petwantsfranch/
   wp-content/plugins/woocommerce/includes/data-stores/class-wc-order-data-store-
   cpt.php(88): do_action(‘woocommerce_new…’, 43819, Object(WC_Order)) #4 /nas/content/
   live/petwantsfranch/wp-content/plugins/woocommerce/includes/class-wc-data-store.
   php(169): WC_Order_Data_Store_CPT->create(Object(WC_Order)) #5 /nas/content/live/
   petwantsfranch/wp-content/plugins/woocommerce/includes/abstracts/abstract-wc-
   order.php(185): WC_Data_Store->create(Object(WC_Order)) #6 /nas/content/live/
   petwants in /nas/content/live/petwantsfranch/wp-content/plugins/order-tip-woo/
   frontend/controllers/main.class.php on line 124
 *  Plugin Author [railmedia](https://wordpress.org/support/users/railmedia/)
 * (@railmedia)
 * [5 years, 4 months ago](https://wordpress.org/support/topic/fatal-error-causing-issues/#post-13704415)
 * Hi there Aaron,
 * Let’s edit the remove_tip_on_order_placed() function once again as follows:
 *     ```
       function remove_tip_on_order_placed( $orderid ) {
   
               if( $this->settings['wc_order_tip_remove_new_order'] ) {
                   $wc_session = WC()->session;
                   if( $wc_session ) {
                       $tip_is_set = $wc_session->get( 'tip' );
                       if( $tip_is_set ) {
                           $wc_session->__unset( 'tip' );
                       }
                   }
               }
   
           }
       ```
   
 *  Thread Starter [smys123](https://wordpress.org/support/users/smys123/)
 * (@smys123)
 * [5 years, 4 months ago](https://wordpress.org/support/topic/fatal-error-causing-issues/#post-13704467)
 * Thanks Adrian,
 * Testing, stand by.
 * Aaron
 *  Thread Starter [smys123](https://wordpress.org/support/users/smys123/)
 * (@smys123)
 * [5 years, 4 months ago](https://wordpress.org/support/topic/fatal-error-causing-issues/#post-13708917)
 * No fatal errors.
 * But it keeps dropping subscriptions into hold.
 * Error message:
    11-24-2020 @ 04:48:03 – scheduled action 109955 (subscription
   payment) failed to finish processing after 300 seconds 11-24-2020 @ 04:48:03 –
   action args: subscription_id: 997
 * All subscriptions are doing this when the plugin is enabled.
 * Thanks for the help!
    Aaron
 *  Plugin Author [railmedia](https://wordpress.org/support/users/railmedia/)
 * (@railmedia)
 * [5 years, 4 months ago](https://wordpress.org/support/topic/fatal-error-causing-issues/#post-13709222)
 * Hi there Aaron,
 * What plugin for subscriptions is the website using?
 *  Thread Starter [smys123](https://wordpress.org/support/users/smys123/)
 * (@smys123)
 * [5 years, 4 months ago](https://wordpress.org/support/topic/fatal-error-causing-issues/#post-13709281)
 * Hey Adrian,
 * We have two:
    WooCommerce All Products For Subscriptions WooCommerce Subscriptions
 * Thanks,
    Aaron
 *  Thread Starter [smys123](https://wordpress.org/support/users/smys123/)
 * (@smys123)
 * [5 years, 4 months ago](https://wordpress.org/support/topic/fatal-error-causing-issues/#post-13727085)
 * Following up on this, our client would love to use this and have the subscriptions
   work over the holidays.
 * Thanks,
    Aaron
 *  Plugin Author [railmedia](https://wordpress.org/support/users/railmedia/)
 * (@railmedia)
 * [5 years, 4 months ago](https://wordpress.org/support/topic/fatal-error-causing-issues/#post-13728869)
 * Hi there Aaron,
 * Let me get this straight. You are trying to use the Order tip with Subscriptions?
   As in adding a tip to each Subscription order automatically?
 * Do you have a staging area I could take a look at?
 * Regards,
    Adrian
 *  Thread Starter [smys123](https://wordpress.org/support/users/smys123/)
 * (@smys123)
 * [5 years, 4 months ago](https://wordpress.org/support/topic/fatal-error-causing-issues/#post-13730855)
 * Correct, and it works on single orders, and actually on the initial subscription
   order. However, it causes the renewals to fail and not process automatically.
 *  Plugin Author [railmedia](https://wordpress.org/support/users/railmedia/)
 * (@railmedia)
 * [5 years, 4 months ago](https://wordpress.org/support/topic/fatal-error-causing-issues/#post-13731015)
 * Hello Aaron,
 * Yes, I understand the problem. However, the plugin does not support at least 
   at the moment WooCommerce Subscriptions or any other subscription based plugin.
 * I will, in any case, look into this matter and should there be a future release
   with subscriptions support, I will let you know.
 * Regards,
    Adrian
 *  Plugin Author [railmedia](https://wordpress.org/support/users/railmedia/)
 * (@railmedia)
 * [5 years, 2 months ago](https://wordpress.org/support/topic/fatal-error-causing-issues/#post-13956135)
 * I will close this topic for the time being. I will be looking into integrating
   the order tips with subscriptions.

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

The topic ‘Fatal Error causing issues’ is closed to new replies.

 * ![](https://ps.w.org/order-tip-woo/assets/icon-128x128.png?rev=2363829)
 * [Order Tip for WooCommerce](https://wordpress.org/plugins/order-tip-woo/)
 * [Support Threads](https://wordpress.org/support/plugin/order-tip-woo/)
 * [Active Topics](https://wordpress.org/support/plugin/order-tip-woo/active/)
 * [Unresolved Topics](https://wordpress.org/support/plugin/order-tip-woo/unresolved/)
 * [Reviews](https://wordpress.org/support/plugin/order-tip-woo/reviews/)

 * 14 replies
 * 2 participants
 * Last reply from: [railmedia](https://wordpress.org/support/users/railmedia/)
 * Last activity: [5 years, 2 months ago](https://wordpress.org/support/topic/fatal-error-causing-issues/#post-13956135)
 * Status: resolved