magento / magento/security-package

reCaptcha JS recaptcha_en.js is added multiple times to head

Open
#331 4 comments 0 reactions 0 assignees View on GitHub

Nobody has claimed this yet.

Progress: ready for grooming
Dominant language
PHP
Stars
75
Forks
73
PR merge metrics
No merged PRs in 30d

Description

### Preconditions (*)

### Steps to reproduce (*)

1. Disabled the Recaptcha for the Product Review section
2. On the product page it's loading JS recaptcha_en.js multiple time

### Expected result (*)

1. Should not Load JS on the product page when disable recaptcha for the Product Review
2. Should not Load JS multiple times.

### Actual result (*)

1. Review JS loaded on the product page when disable recaptcha for the Product Review
2. Should Loading JS multiple times.
3. ![image](https://github.com/magento/security-package/assets/22705393/742c56f6-3bac-494f-840c-ce218bc85c28)

Contributor guide

Open the contributing guide

First steps

  1. Read the whole issue, then the project's contributing guide.
  2. Comment on the issue to say you are picking it up — it saves two people doing the same work.
  3. Fork the repository and make your change on a branch.
  4. Open a pull request that references the issue number.

Research direction

Reproduce the issue on Magento 2.4.2-p1 by disabling reCAPTCHA for Product Review and checking the product page for recaptcha_en.js requests. Trace where the product-page reCAPTCHA assets are added and compare the disabled and enabled configurations. Done means the script is absent when reviews are disabled and is loaded only once when required.

Written by the indexing model from the issue text.

Assessment

Tech stack
javascript, php
Domain
frontend, security
Issue type
Bug
Difficulty
4/5
Estimated time
3-5 days
Activity status
Stale
Clarity
Mostly clear
Newbie friendliness
35/100

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.