Skip to content

Commit

Permalink
fix(loading): parentNode could be null (#1937)
Browse files Browse the repository at this point in the history
* fix(loading): parentNode could be null

* chore: fix ci

* Update package.json
  • Loading branch information
uyarn authored Nov 1, 2022
1 parent 5e40374 commit 5c17aa8
Show file tree
Hide file tree
Showing 2 changed files with 2 additions and 2 deletions.
2 changes: 1 addition & 1 deletion package.json
Original file line number Diff line number Diff line change
Expand Up @@ -87,7 +87,7 @@
"dependencies": {
"@babel/runtime": "^7.14.8",
"@popperjs/core": "^2.9.3",
"@types/lodash": "^4.14.175",
"@types/lodash": "4.14.182",
"@types/sortablejs": "^1.10.7",
"@types/tinycolor2": "^1.4.3",
"@types/validator": "^13.6.3",
Expand Down
2 changes: 1 addition & 1 deletion src/loading/plugin.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -36,7 +36,7 @@ function createLoading(props: TdLoadingProps): LoadingInstance {
const loadingInstance: LoadingInstance = {
hide: () => {
loading.loading = false;
loading.$el.parentNode.removeChild(loading.$el);
loading.$el.parentNode?.removeChild(loading.$el);
removeClass(attach, parentRelativeClass);
},
};
Expand Down

0 comments on commit 5c17aa8

Please sign in to comment.