Define classes with 'var' instead of 'const'
Any symbols (including class properties) that should be visible outside the module it's defined in need to be defined as global. For now gjs still allows the access for 'const', but get rid of the warnings spill now by changing it. https://bugzilla.gnome.org/show_bug.cgi?id=785084
This commit is contained in:
@ -21,7 +21,7 @@ const RfkillManagerInterface = '<node> \
|
||||
|
||||
const RfkillManagerProxy = Gio.DBusProxy.makeProxyWrapper(RfkillManagerInterface);
|
||||
|
||||
const RfkillManager = new Lang.Class({
|
||||
var RfkillManager = new Lang.Class({
|
||||
Name: 'RfkillManager',
|
||||
|
||||
_init: function() {
|
||||
@ -68,7 +68,7 @@ function getRfkillManager() {
|
||||
return _manager;
|
||||
}
|
||||
|
||||
const Indicator = new Lang.Class({
|
||||
var Indicator = new Lang.Class({
|
||||
Name: 'RfkillIndicator',
|
||||
Extends: PanelMenu.SystemIndicator,
|
||||
|
||||
|
Reference in New Issue
Block a user