Skip to content

Commit 47f7c87

Browse files
committed
networking: self.model is always undefined
Stop using `self.model` which is undefined. Instead use the `model` constant defined at the top of `NetworkInterfacePage`. This previously was not a problem because the `model` is only needed when a new connection needs to be created and the autoconnect toggle never used to do that. With non-persistent `Wired Connection` being treated differently the model is now required when toggling autoconnect as new connection is created.
1 parent 11ee008 commit 47f7c87

File tree

1 file changed

+1
-1
lines changed

1 file changed

+1
-1
lines changed

pkg/networkmanager/network-interface.jsx

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -306,7 +306,7 @@ export const NetworkInterfacePage = ({
306306
<Checkbox id="autoreconnect" isDisabled={!privileged}
307307
onChange={(_event, checked) => {
308308
settings.connection.autoconnect = checked;
309-
settings_applier(self.model, dev, con)(settings);
309+
settings_applier(model, dev, con)(settings);
310310
}}
311311
isChecked={settings.connection.autoconnect}
312312
label={_("Connect automatically")} />

0 commit comments

Comments
 (0)