Skip to content

ActionItem with *ngIf throws an error when it's removed #4691

Closed
@madakk

Description

@madakk

Looks like this is happening because ActionItems.removeItems calls _removeView directly:

this._actionBar._removeView(item);

But the nativescript angular handler has already removed the view (due to the same *ngIf directive) causing the error.

I believe this can be fixed by simply checking that the item's parent is actually the actionBar before attempting to remove it.

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