Thanks to visit codestin.com
Credit goes to github.com

Skip to content

fix: avoid errors when executing unfinished operations after dispose#1031

Merged
plainheart merged 3 commits into
ecomfe:masterfrom
yechunxi:master
Dec 20, 2023
Merged

fix: avoid errors when executing unfinished operations after dispose#1031
plainheart merged 3 commits into
ecomfe:masterfrom
yechunxi:master

Conversation

@yechunxi
Copy link
Copy Markdown
Contributor

A chart is performing certain operations. After the operation, it will be refreshed and calling flush. At this time, the instance has been disposed, an error will appear. such this issue and in react native echart issue

@zhiqingchen
Copy link
Copy Markdown

@plainheart Can you review this pr?

Copy link
Copy Markdown
Collaborator

@plainheart plainheart left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Thanks for your contribution! I would prefer adding a flag _disposed and checking it before invoking the instance methods, as ECharts does.

https://github.com/apache/echarts/blob/master/src/core/echarts.ts#L1168-L1185

@yechunxi yechunxi marked this pull request as draft December 19, 2023 08:32
@yechunxi yechunxi requested a review from plainheart December 19, 2023 09:39
@yechunxi yechunxi marked this pull request as ready for review December 19, 2023 09:39
@yechunxi
Copy link
Copy Markdown
Contributor Author

Thanks for your contribution! I would prefer adding a flag _disposed and checking it before invoking the instance methods, as ECharts does.

https://github.com/apache/echarts/blob/master/src/core/echarts.ts#L1168-L1185

Thank you, your suggestion will be better. Based on the suggestions you gave me, I implemented it again. I hope to review it

@yechunxi yechunxi closed this Dec 19, 2023
@yechunxi yechunxi reopened this Dec 19, 2023
@AkshayPathakMLF
Copy link
Copy Markdown

@plainheart Are you able to release a new version since this has been merged in?

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

TypeError: Cannot read properties of null (reading 'start')

4 participants