Axo: Remove the submit button when Fastlane is disabled

This commit is contained in:
Daniel Dudzic 2024-10-21 11:05:12 +02:00
parent 53af77897f
commit bf52b48ae8
No known key found for this signature in database
GPG key ID: 31B40D33E3465483

View file

@ -222,8 +222,10 @@ class AxoModule implements ServiceModule, ExtendingModule, ExecutableModule {
// Render submit button. // Render submit button.
add_action( add_action(
$manager->checkout_button_renderer_hook(), $manager->checkout_button_renderer_hook(),
static function () use ( $c, $manager ) { static function () use ( $c, $manager, $module ) {
$manager->render_checkout_button(); if ( $module->should_render_fastlane( $c ) ) {
$manager->render_checkout_button();
}
} }
); );