Problem/Motivation

Using [commerce_product:current_variation:url:absolute] in metatags of a translated product variation returns the absolute URL in the default language, not the current language.

So the value returns e.g. a German URL for a product variation shown in English.
This is not a caching issue, I rebuilt caches but the issue still exists.

Might be similar to #3160546: Explicitly pass current language to Token::replace() in \Drupal\commerce_payment\Plugin\Commerce\PaymentGateway\Manual::buildPaymentInstructions()

Steps to reproduce

Proposed resolution

Remaining tasks

User interface changes

Introduced terminology

API changes

Data model changes

Release notes snippet

Comments

anybody created an issue.

anybody’s picture

As workaround I'm for now using https://www.drupal.org/project/token_url_plus and the token:
[current-page:url-with-query:with-some-parameters:v]
but that's not more than a workaround. Root cause needs to be fixed.