cleanup: Remove spaces in object literals
We only adopted this style relatively recently, so there's a bit more to adjust. Still, it's manageable and another step towards getting rid of the legacy style. Part-of: <https://gitlab.gnome.org/GNOME/gnome-shell/-/merge_requests/2866>
This commit is contained in:

committed by
Marge Bot

parent
6a22af83dc
commit
071f92cfb6
@ -52,7 +52,7 @@ let _desktopSettings = null;
|
||||
export function findUrls(str) {
|
||||
let res = [], match;
|
||||
while ((match = _urlRegexp.exec(str)))
|
||||
res.push({ url: match[2], pos: match.index + match[1].length });
|
||||
res.push({url: match[2], pos: match.index + match[1].length});
|
||||
return res;
|
||||
}
|
||||
|
||||
@ -143,7 +143,7 @@ function trySpawn(argv) {
|
||||
// We are only interested in the part in the parentheses. (And
|
||||
// we can't pattern match the text, since it gets localized.)
|
||||
let message = err.message.replace(/.*\((.+)\)/, '$1');
|
||||
throw new err.constructor({ code: err.code, message });
|
||||
throw new err.constructor({code: err.code, message});
|
||||
} else {
|
||||
throw err;
|
||||
}
|
||||
@ -196,9 +196,9 @@ function _handleSpawnError(command, err) {
|
||||
*/
|
||||
export function createTimeLabel(date, params) {
|
||||
if (_desktopSettings == null)
|
||||
_desktopSettings = new Gio.Settings({ schema_id: 'org.gnome.desktop.interface' });
|
||||
_desktopSettings = new Gio.Settings({schema_id: 'org.gnome.desktop.interface'});
|
||||
|
||||
let label = new St.Label({ text: formatTime(date, params) });
|
||||
let label = new St.Label({text: formatTime(date, params)});
|
||||
_desktopSettings.connectObject(
|
||||
'changed::clock-format', () => (label.text = formatTime(date, params)),
|
||||
label);
|
||||
|
Reference in New Issue
Block a user