refactoring due to facebook/react/pull/15047

This commit is contained in:
or-else
2019-08-15 10:30:29 +03:00
parent f1744c3f69
commit 0217d84721
23 changed files with 192 additions and 161 deletions
+2 -1
View File
@@ -56,8 +56,9 @@ export default class Attachment extends React.Component {
if (!this.props.uploader && !this.state.downloader &&
!(/^(?:(?:[a-z]+:)?\/\/)/i.test(this.props.downloadUrl))) {
// Relative URL. Use download helper.
url = "javascript:;";
url = '#';
helperFunc = (e) => {
e.preventDefault();
this.downloadFile(this.props.downloadUrl, this.props.filename, this.props.mimetype);
};
} else {