Skip to content

fix: 🐛 Fix operator precedence in About customer URL href#57

Draft
wapec wants to merge 1 commit intoEuro-Office:mainfrom
wapec:fix/about-url-operator-precedence
Draft

fix: 🐛 Fix operator precedence in About customer URL href#57
wapec wants to merge 1 commit intoEuro-Office:mainfrom
wapec:fix/about-url-operator-precedence

Conversation

@wapec
Copy link
Copy Markdown

@wapec wapec commented May 5, 2026

The ternary and string concatenation were not grouped correctly — due to operator precedence, the expression evaluated as:
condition ? 'http://' : urlCustomer
instead of:
(condition ? 'http://' : '') + urlCustomer

When urlCustomer had no scheme, href became 'http://' with the actual URL silently dropped. Affects all white-labelled installations supplying customization.customer.www without a protocol prefix.

The ternary and string concatenation were not grouped correctly — due to
operator precedence, the expression evaluated as:
  condition ? 'http://' : urlCustomer
instead of:
  (condition ? 'http://' : '') + urlCustomer

When urlCustomer had no scheme, href became 'http://' with the actual
URL silently dropped. Affects all white-labelled installations supplying
customization.customer.www without a protocol prefix.

Signed-off-by: Bohdan Baranov <wapec@icloud.com>
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant