My FIles: Don't get stuck on loading screen if no files are present

This commit is contained in:
Alex Liebowitz 2016-10-19 20:29:35 -04:00
parent 48d30a5cb7
commit 2ad8960e2f

View file

@ -166,6 +166,13 @@ var MyFilesPage = React.createClass({
},
getFilesOwnership: function() {
lbry.getFilesInfo((filesInfo) => {
if (!filesInfo) {
this.setState({
filesOwnershipLoaded: true,
});
return;
}
var ownershipLoadedCount = 0;
for (let i = 0; i < filesInfo.length; i++) {
let fileInfo = filesInfo[i];