Skip to content

fix: replace var with const/let and add radix to parseInt in _spaceCatcher #52

Description

@coderabbitai

Summary

Pre-existing SonarCloud findings in _spaceCatcher (l2t-paper-slider.js) that were present on master before PR #51 are now surfacing in the SonarCloud diff analysis for that PR because the function was modified.

Findings

  1. var declaration (SonarCloud failure): var nextPos should be const nextPos (or let if reassigned).
  2. parseInt without explicit radix (SonarCloud warning): parseInt(nextPos) should be Number.parseInt(nextPos, 10).

Impact

The var finding is a SonarCloud failure (not merely a warning) and may block the quality gate on any future PR that touches this function.

Suggested fix

const nextPos = activeEl.getAttribute('aria-posinset');
if (nextPos) this.movePos(Number.parseInt(nextPos, 10) - 1);

References

Activity

  1. moved this from Inbox (needs triage) to In Progress in Flowing Code Addonson May 7, 2026
  2. self-assigned this
    on May 7, 2026
  3. javier-godoy commented on May 11, 2026

    @javier-godoy
    Member

    Fixed in PR #51.

  4. javier-godoy commented on May 11, 2026

    @javier-godoy
    Member

    Fix released in v3.0.2

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Metadata

Metadata

Assignees

Labels

No labels
No labels

Type

No type

Projects

Milestone

No milestone

Relationships

None yet

Development

No branches or pull requests

Issue actions