diff --git a/includes/RestApi/EventsController.php b/includes/RestApi/EventsController.php index 6cd089729..f55537bbd 100644 --- a/includes/RestApi/EventsController.php +++ b/includes/RestApi/EventsController.php @@ -76,6 +76,10 @@ public function send_event( \WP_REST_Request $request ) { $event['data'] = $request->get_param( 'data' ); + if ( ! empty( $event['data'] ) && ! empty( $event['data']['stepID'] ) ) { + $event['data']['page'] = \admin_url( '/index.php?page=nfd-onboarding#' . $event['data']['stepID'] ); + } + $event_data_request = new \WP_REST_Request( \WP_REST_Server::CREATABLE, NFD_MODULE_DATA_EVENTS_API