Greasemonkey: add assert to tests scripts_for assumptions.
And crash the users browsing session as a result of any accidental and totally, otherwise, non-fatal unforseen errors.
This commit is contained in:
parent
0381d74e9a
commit
129f97873a
@ -323,6 +323,8 @@ class BrowserPage(QWebPage):
|
||||
# also indicate a bug.
|
||||
log.greasemonkey.debug("Not running scripts for frame with no "
|
||||
"url: {}".format(frame))
|
||||
assert not toload, toload
|
||||
|
||||
for script in toload:
|
||||
if frame is self.mainFrame() or script.runs_on_sub_frames:
|
||||
log.webview.debug('Running GM script: {}'.format(script.name))
|
||||
|
Loading…
Reference in New Issue
Block a user