Skip to content

Call to extractClasses seems to use path as file content incorrectly. #5864

@wmatosjr

Description

@wmatosjr

testElementList.push(...extractClasses(editor.document.fileName, languageConfig.classExtractionPattern))

Shouldn't this be looking at the content of the editor.document.fileName and not the path? Call to extractClasses attempts to extract classes from the path, resulting is this function always returning empty list. Line should be:

testElementList.push(...extractClasses(testFileContent, languageConfig.classExtractionPattern))

Metadata

Metadata

Assignees

No one assigned

    Labels

    amazon-qbugWe can reproduce the issue and confirmed it is a bug.codewhisperer

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions