WPLMS: How to redirect a user to my account page after checkout?

How to redirect

If as a course creator in WPLMS 4.0 , you desire to send the student/user to be redirected to their account page, you need to use the code in your wplms-customizer.php file in your wplms customizer plugin.

<!-- wp:paragraph -->
<p><code>add_action( 'template_redirect', 'wc_custom_redirect_after_purchase' ); function wc_custom_redirect_after_purchase() { global $wp; if ( is_checkout() &amp;&amp; ! empty( $wp-&gt;query_vars['order-received'] ) ) { wp_redirect( get_permalink( get_option('woocommerce_myaccount_page_id') ) ); exit; } }</code></p>
<!-- /wp:paragraph -->