style: codacy fixes

This commit is contained in:
David Ralph
2021-08-21 11:11:00 +01:00
parent ef2f666ccf
commit 490f42a9ad
16 changed files with 28 additions and 23 deletions

View File

@@ -153,7 +153,8 @@ export default class Background extends PureComponent {
photographerURL: photographerURL,
photoURL: photoURL
}
}
};
this.setState(object);
localStorage.setItem('currentBackground', JSON.stringify(object));

View File

@@ -52,7 +52,7 @@ export default function PhotoInformation(props) {
img.onload = (event) => {
setWidth(event.target.width);
setHeight(event.target.height);
}
};
img.src = (localStorage.getItem('ddgProxy') === 'true' && !props.info.offline && !props.url.startsWith('data:')) ? window.constants.DDG_IMAGE_PROXY + props.url : props.url;
// info is still there because we want the favourite button to work