canonical url and transform updates #38

Merged
akinwale merged 7 commits from 0.8.4-rc into master 2019-09-06 20:43:48 +02:00
Showing only changes of commit 1dc85cc4c9 - Show all commits

View file

@ -13,6 +13,10 @@ import ProgressBar from 'component/progressBar';
import fileListStyle from 'styles/fileList';
class FileListItem extends React.PureComponent {
state = {
url: null,
};
getStorageForFileInfo = fileInfo => {
if (!fileInfo.completed) {
const written = formatBytes(fileInfo.written_bytes);
@ -44,8 +48,8 @@ class FileListItem extends React.PureComponent {
componentDidUpdate() {
const { claim, resolveUri, uri } = this.props;
if (!claim) {
resolveUri(uri);
if (!claim && uri !== this.state.url) {
this.setState({ url: uri }, () => resolveUri(uri));
}
}