fix browser blank page on gateways (#8453)

StorageInfo component will not be rendered if
Storage used is null.
This commit is contained in:
Kanagaraj M
2019-10-28 23:18:02 +05:30
committed by kannappanr
parent a2825702f8
commit 4e6bf136a8
3 changed files with 58 additions and 39 deletions
+7 -1
View File
@@ -26,7 +26,13 @@ export class StorageInfo extends React.Component {
}
render() {
const { used } = this.props.storageInfo
var totalUsed = used.reduce((v1, v2) => v1 + v2, 0)
if (!used) {
return <noscript />
}
const totalUsed = used.reduce((v1, v2) => v1 + v2, 0)
return (
<div className="feh-used">
<div className="fehu-chart">