Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

fix: 防止手动设置 selectedRowKeys 为 undefined 时,derivedSelectedKeys 为 undefined,导致 js crash。 #28193

Merged
merged 3 commits into from
Dec 4, 2020

Conversation

yanguoyu
Copy link
Contributor

@yanguoyu yanguoyu commented Dec 4, 2020

[中文版模板 / Chinese template]

🤔 This is a ...

  • New feature
  • Bug fix
  • Site / documentation update
  • Demo update
  • Component style update
  • TypeScript definition update
  • Bundle size optimization
  • Performance optimization
  • Enhancement feature
  • Internationalization
  • Refactoring
  • Code style optimization
  • Test Case
  • Branch merge
  • Other (about what?)

🔗 Related issue link

fix #28174

💡 Background and solution

📝 Changelog

Language Changelog
🇺🇸 English
🇨🇳 Chinese

☑️ Self Check before Merge

⚠️ Please check all items below before review. ⚠️

  • Doc is updated/provided or not needed
  • Demo is updated/provided or not needed
  • TypeScript definition is updated/provided or not needed
  • Changelog is provided or not needed

@yanguoyu yanguoyu changed the title 1:防止手动设置 selectedRowKeys 为 undefined 时,derivedSelectedKeys 为 undefind,导致 js crash。 fixed 28174 Dec 4, 2020
@yanguoyu yanguoyu changed the title fixed 28174 fixed: 28174 Dec 4, 2020
@ant-design-bot
Copy link
Contributor

ant-design-bot commented Dec 4, 2020

@codesandbox-ci
Copy link

codesandbox-ci bot commented Dec 4, 2020

This pull request is automatically built and testable in CodeSandbox.

To see build info of the built libraries, click here or the icon next to each commit SHA.

Latest deployment of this branch, based on commit 2c6940d:

Sandbox Source
antd reproduction template Configuration

@github-actions
Copy link
Contributor

github-actions bot commented Dec 4, 2020

Size Change: +6 B (0%)

Total Size: 790 kB

Filename Size Change
./dist/antd-with-locales.min.js 313 kB +3 B (0%)
./dist/antd.min.js 275 kB +3 B (0%)
ℹ️ View Unchanged
Filename Size Change
./dist/antd.compact.min.css 66.7 kB 0 B
./dist/antd.dark.min.css 68 kB 0 B
./dist/antd.min.css 66.7 kB 0 B

compressed-size-action

@afc163
Copy link
Member

afc163 commented Dec 4, 2020

图片

@yanguoyu yanguoyu changed the title fixed: 28174 fixed: 防止手动设置 selectedRowKeys 为 undefined 时,derivedSelectedKeys 为 undefined,导致 js crash。 Dec 4, 2020
@yanguoyu yanguoyu changed the title fixed: 防止手动设置 selectedRowKeys 为 undefined 时,derivedSelectedKeys 为 undefined,导致 js crash。 fix: 防止手动设置 selectedRowKeys 为 undefined 时,derivedSelectedKeys 为 undefined,导致 js crash。 Dec 4, 2020
@afc163 afc163 merged commit 4790ef5 into ant-design:master Dec 4, 2020
@ycjcl868 ycjcl868 mentioned this pull request Dec 6, 2020
vouis pushed a commit to vouis/ant-design that referenced this pull request Dec 10, 2020
…ined,导致 js crash。 (ant-design#28193)

* 1:防止手动设置 selectedRowKeys 为 undefined 时,derivedSelectedKeys 为 undefined,导致 js crash。

* fixed: 防止手动设置 selectedRowKeys 为 undefined 时,derivedSelectedKeys 为 undefined,导致 js crash。
vouis pushed a commit to vouis/ant-design that referenced this pull request Dec 10, 2020
…ined,导致 js crash。 (ant-design#28193)

* 1:防止手动设置 selectedRowKeys 为 undefined 时,derivedSelectedKeys 为 undefined,导致 js crash。

* fixed: 防止手动设置 selectedRowKeys 为 undefined 时,derivedSelectedKeys 为 undefined,导致 js crash。
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.

Table with rowSelection error,it should be more strong。带选择框的 Table 应该更健壮。
3 participants