[AGS] Potential fix for network crash
This commit is contained in:
parent
a8e0c903c4
commit
d72c4fdf86
@ -29,7 +29,10 @@ const Network = () => {
|
||||
)}
|
||||
cssClasses={["title-2"]}
|
||||
></label>
|
||||
<label
|
||||
<box child=
|
||||
{bind(net, 'wired').as(v => {
|
||||
if (v) {
|
||||
return <label
|
||||
label={bind(net.wired, "state").as(state => {
|
||||
if (state === STATE.ACTIVATED) {
|
||||
return (
|
||||
@ -52,6 +55,10 @@ const Network = () => {
|
||||
})}
|
||||
visible={bind(net.wifi, "enabled").as(v => !v)}
|
||||
></label>
|
||||
} else {
|
||||
return <label label={"State unavailable"}></label>
|
||||
}
|
||||
})}></box>
|
||||
<label
|
||||
label={bind(net.wifi, "state").as(state => {
|
||||
if (state === STATE.ACTIVATED) {
|
||||
@ -75,7 +82,7 @@ const Network = () => {
|
||||
></label>
|
||||
</box>
|
||||
}
|
||||
></button>
|
||||
></button >
|
||||
<button
|
||||
cssClasses={["actions-button"]}
|
||||
visible={networkHelper.networkEnabled()}
|
||||
@ -83,12 +90,12 @@ const Network = () => {
|
||||
child={
|
||||
<box>
|
||||
<image iconName={"arrow-right-symbolic"}></image>
|
||||
{ netMenu }
|
||||
{netMenu}
|
||||
</box>
|
||||
}
|
||||
tooltipText={"View available devices"}
|
||||
></button>
|
||||
</box>
|
||||
</box >
|
||||
);
|
||||
};
|
||||
|
||||
|
Loading…
x
Reference in New Issue
Block a user