cleanup: Don't shadow variables
Having variables that share the same name in overlapping scopes is confusing and error-prone, and is best avoided. https://gitlab.gnome.org/GNOME/gnome-shell/merge_requests/805
This commit is contained in:

committed by
Georges Basile Stavracas Neto

parent
2e4e2500dd
commit
682bd7e97c
@ -996,7 +996,7 @@ class NotificationSection extends MessageList.MessageListSection {
|
||||
notificationAddedId: 0,
|
||||
};
|
||||
|
||||
obj.destroyId = source.connect('destroy', source => {
|
||||
obj.destroyId = source.connect('destroy', () => {
|
||||
this._onSourceDestroy(source, obj);
|
||||
});
|
||||
obj.notificationAddedId = source.connect('notification-added',
|
||||
@ -1170,7 +1170,7 @@ class CalendarMessageList extends St.Widget {
|
||||
Util.ensureActorVisibleInScrollView(this._scrollView, messageActor);
|
||||
}));
|
||||
|
||||
connectionsIds.push(section.connect('destroy', (section) => {
|
||||
connectionsIds.push(section.connect('destroy', () => {
|
||||
connectionsIds.forEach(id => section.disconnect(id));
|
||||
this._sectionList.remove_actor(section);
|
||||
}));
|
||||
|
Reference in New Issue
Block a user