js: Use templates for non-translatable strings

This reverts commit 9d941f8202 and replaces all additional
instances of .format() that have been added since.

Part-of: <https://gitlab.gnome.org/GNOME/gnome-shell/-/merge_requests/2160>
This commit is contained in:
Florian Müllner
2022-02-07 15:14:06 +01:00
committed by Marge Bot
parent 29dfde5a4a
commit a1dd1b25d8
51 changed files with 254 additions and 261 deletions

View File

@ -112,7 +112,7 @@ var AutomountManager = class {
try {
drive.stop_finish(res);
} catch (e) {
log('Unable to stop the drive after drive-eject-button %s'.format(e.toString()));
log(`Unable to stop the drive after drive-eject-button ${e.toString()}`);
}
});
} else if (drive.can_eject()) {
@ -121,7 +121,7 @@ var AutomountManager = class {
try {
drive.eject_with_operation_finish(res);
} catch (e) {
log('Unable to eject the drive after drive-eject-button %s'.format(e.toString()));
log(`Unable to eject the drive after drive-eject-button ${e.toString()}`);
}
});
}
@ -208,7 +208,7 @@ var AutomountManager = class {
}
if (!e.matches(Gio.IOErrorEnum, Gio.IOErrorEnum.FAILED_HANDLED))
log('Unable to mount volume %s: %s'.format(volume.get_name(), e.toString()));
log(`Unable to mount volume ${volume.get_name()}: ${e.toString()}`);
this._closeOperation(volume);
}
}