VotingApiWidgetBase::getVoteSummary method doesn't work correctly.

Created on 13 January 2021, almost 4 years ago
Updated 16 January 2023, almost 2 years ago

Steps to reproduce

Create two fields with voting_api_widgets in one entity, name them as field_five_stars and field_five_stars_2.
Current logic in VotingApiWidgetBase::getVoteSummary next strrpos($key, $field_name) !== FALSE. So this check will always pass as long as fields will have same signature.

πŸ› Bug report
Status

Needs work

Version

1.0

Component

Code

Created by

πŸ‡ΊπŸ‡¦Ukraine dinazaur

Live updates comments and jobs are added and updated live.
  • Needs tests

    The change is currently missing an automated test that fails when run with the original code, and succeeds when the bug has been fixed.

Sign in to follow issues

Comments & Activities

Not all content is available!

It's likely this issue predates Contrib.social: some issue and comment data are missing.

  • Status changed to Needs work almost 2 years ago
Production build 0.71.5 2024