Skip to content
This repository was archived by the owner on May 1, 2025. It is now read-only.
This repository was archived by the owner on May 1, 2025. It is now read-only.

valRegex improperly referenced #77

@derek-rmd

Description

@derek-rmd

ret.value = org.replace(this.valReqex, '');

  • should be this.valRegex not this.valReqex
  • but then this will replace all valid characters with '', instead of invalid chars
  • and is also overwritten for ^ and $ a few lines below
    • this should be ret.value = `^${ret.value}`; instead
  • an option like escapeRegex: true might be more appropriate here
    • or escapeRegexChars: /[\\^$.*+?()[\]{}|]/g, where use s.replace(this.escapeRegexChars, '\\$&') to escape (source: lodash _.escapeRegex)

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type
    No fields configured for issues without a type.

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions