Skip to content

constants.js Returning Undefined For Some Keys #3361

Description

@aaronskiba

Please complete the following fields as applicable:

What version of the DMPRoadmap code are you running? (e.g. v2.2.0)

  • v4.1.1

Checking which constants aren't being returned:

  • Screenshot from 2023-12-11 10-23-43

  • Screenshot from 2023-12-11 10-25-31

  1. getConstant('VALIDATION_MESSAGE_PASSWORDS_MATCH') is being called by app/javascript/src/utils/passwordHelper.js. However, the key VALIDATION_MESSAGE_PASSWORDS_MATCH does not exist in constants_json (app/views/layouts/application.html.erb).

  2. REQUIRED_FIELD_TEXT does exist in constants_json. However, app/javascript/src/utils/requiredField.js is calling getConstant('REQUIRED_FIELD_TEXT') before the constant is loaded to constants.js.

Screenshot from 2023-12-11 11-32-01

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