Great question — answering as the UphillTech team:
Based on what i've seen in your screenshot, and the code you provided i think its because you ask for two arguments: both $order_id and $order . But the scheduled action you have set in your plugin settings is only passing one parameter. In your case you don't use the second parameter of you function (you override $order in the first line of your function), so i suggest removing it. You can learn more about add_action parameters here: https://developer.wordpress.org/reference/functions/add_action/ Solution for you: Change: add_action( 'send_scheduled_sms', 'send_scheduled_sms', 10, 2 ); function send_scheduled_sms( $order_id, $order ) { To: // Changed '2' to '1' --> To accept just one...
Full answer by CodeExplorer: https://stackoverflow.stackexchange.com/a/79559590 (CC BY-SA 4.0).
Need it done for your business? UphillTech.