Skip to content

TypeError: Cannot read property 'delegate' of null at ExRouter.componentWillUnmount  #277

Closed
@seantempesta

Description

@seantempesta

I'm hitting an exception if I rapidly switch between routes in the iOS Simulator. Looks like it's in ExRouter.js (lines 197-201):

    componentWillUnmount() {
        if (this === Actions.currentRouter.delegate) {
            Actions.currentRouter = null;
        }
    }

The component is checking currentRouter for this delegate property, but it's already null. Has anyone else hit this issue? I guess the problem could be fixed by checking if it's already null?

I don't really know how to repro the issue as it happens randomly when I'm clicking around really fast in my app.

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions