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

1.8.0 to 1.9.0 "this._fileBrowser.child" is undefined #249

@Deep-Patidar

Description

@Deep-Patidar

Hi, I am sort of new in react and trying to update a project, the current version my project has is 1.8.0 and when i tried to update it to 1.9.0 , it started giving my error of undefined value
like i tried to
console.log (this._fileBrowser.child)
it gives value in 1.8.0 but in 1.9.0 it says undefined
I searched everywhere but was not able to find anything to resolve this issue ,
here is some part of my code.
getting error in this line
this.setState({
files: files, hasNext: response.data.has_next, lastPage: page, pageCount: response.data.count
}, () => {
window.removeEventListener('click', this._fileBrowser.child.handleGlobalClick);
window.addEventListener('click', this.handleGlobalClick);
});

this is the part where its getting its value
<FileBrowser
files={this.state.files}
canFilter={false}
ref={el => {
this._fileBrowser = el
}}

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions