Skip to content

[bug] Web crashes with unexpected error "e.indexOf is not a function" if a repository contains a folder called "constructor" #861

@olegvodyanov

Description

@olegvodyanov

Describe the bug

Hi all.

The Sourcebot UI crashes while rendering the VS Code-style folder icon when a folder is named "constructor"
The icon resolver returns a non-string value (object) for this folder name, which then causes the runtime exception.

To reproduce

Create (or have) a folder named constructor in the tree/file browser.
Open the page that renders the folder tree.
Expand/navigate to the folder list so that the "constructor" folder is visible and the icon is rendered.

Sourcebot deployment information

Sourcebot version: v4.10.27

Additional information

No response

Metadata

Metadata

Labels

Type

No type

Projects

No projects

Milestone

No milestone

Relationships

None yet

Development

No branches or pull requests

Issue actions