Patched prototypes should only be restored in the disable() method of the extension, since gnome enforces extension rebasing when disabling them. Restoring protos in any other place may lead to infinite recursion if a different extension is also patching the same function.
Patched prototypes should only be restored in the
disable()
method of the extension, since gnome enforces extension rebasing when disabling them. Restoring protos in any other place may lead to infinite recursion if a different extension is also patching the same function.See https://gitlab.gnome.org/ewlsh/gjs-guide/-/issues/75, https://gitlab.gnome.org/GNOME/gnome-shell/-/issues/7629
Fixes: #585