🐛 Fix errors in lgtm.com

https://lgtm.com/projects/g/ant-design/ant-design/alerts/?mode=list
This commit is contained in:
afc163 2019-01-28 11:52:40 +08:00 committed by 偏右
parent 8838bd602d
commit 5de5f4c458
2 changed files with 2 additions and 7 deletions

View File

@ -100,8 +100,7 @@ class TextArea extends React.Component<TextAreaProps, TextAreaState> {
if (!autosize || !this.textAreaRef) {
return;
}
const minRows = autosize ? (autosize as AutoSizeType).minRows : null;
const maxRows = autosize ? (autosize as AutoSizeType).maxRows : null;
const { minRows, maxRows } = autosize as AutoSizeType;
const textareaStyles = calculateNodeHeight(this.textAreaRef, false, minRows, maxRows);
this.setState({ textareaStyles });
};

View File

@ -17,11 +17,7 @@
<!--[if lte IE 10]>
<script src="https://as.alipayobjects.com/g/component/??console-polyfill/0.2.2/index.js,media-match/2.0.2/media.match.min.js"></script>
<![endif]-->
<script>
if (!window.Intl) {
document.writeln('<script src="https://as.alipayobjects.com/g/component/intl/1.0.1/??Intl.js,locale-data/jsonp/en.js,locale-data/jsonp/zh.js"\>\<\/script>');
}
</script>
<script src="https://as.alipayobjects.com/g/component/intl/1.0.1/??Intl.min.js,locale-data/jsonp/en.js,locale-data/jsonp/zh.js"></script>
<script>
(function() {
function isLocalStorageNameSupported() {