klaviyo / magento2-klaviyo

37 stars 51 forks source link

E-Mail not encoded in searchProfileByEmail #295

Closed spicyavocadooo closed 3 weeks ago

spicyavocadooo commented 2 months ago

Environment details

PHP version: 8.1 Magento version: 2.4.6-p4 Klaviyo extension version: 4.1.3 Anything else that would help a developer reproduce the bug?

Steps to reproduce

Create customer with email address including "+" symbol Unsubscribe Customer Subscribe Customer again

Expected result

Customer is subscribed to newsletter after subscribing again

Actual result

Customer is not subscribed to newsletter after subscribing again, exception in log "Unable to subscribe ... to list ...: Klaviyo\Reclaim\KlaviyoV3Sdk\Exception\KlaviyoApiException: A profile already exists with one of these identifiers."

Additional information

searchProfileByEmail is using normal email and not encoded email as necessary for the API

cykolln commented 2 months ago

Thanks for opening - we need to add urlencode around the email in searchProfileByEmail. We've added this to our backlog and can include it in our next release. This is only an issue when the option to not use Klaviyo consent is selected in the extension settings.

cykolln commented 3 weeks ago

This has been fixed in 4.1.4