status/network: Compare icon name to NULL instead of empty string

Since the last commit we set the gicon property of StIcon to NULL if an
empty string was given when setting the icon name, this means
`st_icon_get_icon_name()` will return NULL instead of an empty string.

When `getIndicatorIcon()` returns an empty string, the icon_name
property will now be set to NULL, so compare it to NULL here.

https://gitlab.gnome.org/GNOME/gnome-shell/merge_requests/888
This commit is contained in:
Jonas Dreßler 2019-11-21 16:04:12 +07:00 committed by Florian Müllner
parent 8b15519160
commit aac01f1c9e

View File

@ -2069,6 +2069,6 @@ class Indicator extends PanelMenu.SystemIndicator {
} }
this._vpnIndicator.icon_name = this._vpnSection.getIndicatorIcon(); this._vpnIndicator.icon_name = this._vpnSection.getIndicatorIcon();
this._vpnIndicator.visible = this._vpnIndicator.icon_name != ''; this._vpnIndicator.visible = this._vpnIndicator.icon_name !== null;
} }
}); });