mirror of
https://github.com/edu4rdshl/gnome-shell.git
synced 2026-07-17 23:24:51 +00:00
js: Throw GObject.NotImplementedError when requiring overriding
Since version 1.50.0, gjs defines GObject.NotImplementedError for throwing errors when a "virtual" method that requires a subclass implementation is not defined. So use this instead of a generic JS Error in such cases. https://gitlab.gnome.org/GNOME/gnome-shell/merge_requests/549
This commit is contained in:
parent
4730b7a094
commit
88697add1b
5 changed files with 8 additions and 7 deletions
|
|
@ -124,7 +124,7 @@ var Batch = class extends Task {
|
|||
}
|
||||
|
||||
process() {
|
||||
throw new Error('Not implemented');
|
||||
throw new GObject.NotImplementedError(`process in ${this.constructor.name}`);
|
||||
}
|
||||
|
||||
runTask() {
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue