diff --git a/modules/ppcp-api-client/src/Authentication/SdkClientToken.php b/modules/ppcp-api-client/src/Authentication/SdkClientToken.php index 377dd144a..1d097a5ab 100644 --- a/modules/ppcp-api-client/src/Authentication/SdkClientToken.php +++ b/modules/ppcp-api-client/src/Authentication/SdkClientToken.php @@ -70,8 +70,10 @@ class SdkClientToken { */ public function sdk_client_token( string $target_customer_id = '' ): string { $bearer = $this->bearer->bearer(); + $domain = $_SERVER['HTTP_HOST']; + + $url = trailingslashit( $this->host ) . 'v1/oauth2/token?grant_type=client_credentials&response_type=client_token&intent=sdk_init&domains[]=*.' . $domain; - $url = trailingslashit( $this->host ) . 'v1/oauth2/token?grant_type=client_credentials&response_type=client_token&intent=sdk_init'; if ( $target_customer_id ) { $url = add_query_arg( array( diff --git a/modules/ppcp-axo/resources/js/AxoManager.js b/modules/ppcp-axo/resources/js/AxoManager.js index 959e3b1e3..a8197575d 100644 --- a/modules/ppcp-axo/resources/js/AxoManager.js +++ b/modules/ppcp-axo/resources/js/AxoManager.js @@ -451,10 +451,10 @@ class AxoManager { this.el.gatewayRadioButton.trigger('change'); } - renderWatermark() { - this.fastlane.FastlaneWatermarkComponent({ + async renderWatermark() { + (await this.fastlane.FastlaneWatermarkComponent({ includeAdditionalInfo: true - }).render(this.el.watermarkContainer.selector); + })).render(this.el.watermarkContainer.selector); } watchEmail() {