Failing unwrapped scripts are executed twice
Reported by Olivier Cornu | March 23rd, 2009 @ 02:39 PM | in 0.1a1
For backward compatibility purposes, following script wrapping mess in previous GM releases, we're left with the following code:
if (!script.unwrap)
scriptSrc = "(function(){"+ scriptSrc +"})()";
if (!this.evalInSandbox(scriptSrc, url, sandbox, script) && script.unwrap)
this.evalInSandbox("(function(){"+ scriptSrc +"})()",
url, sandbox, script); // wrap anyway on early return
In other words, if an unwrapped script fails to execute properly, it is wrapped and executed again. This might result in a page being (at least partly) modified twice.
Scripts failing because of @unwrap
issues should be
fixed, not "hot-patched" like this.
Comments and changes to this ticket
-
Olivier Cornu March 24th, 2009 @ 11:36 AM
- State changed from new to resolved
(from [5dfd6fc9fcc60b23084c59007bebcf7462c2e853]) Don't execute failing unwrapped scripts twice [#9 state:resolved] http://github.com/ocornu/webmonk...
Please Sign in or create a free account to add a new ticket.
With your very own profile, you can contribute to projects, track your activity, watch tickets, receive and update tickets through your email and much more.
Create your profile
Help contribute to this project by taking a few moments to create your personal profile. Create your profile ยป
Webmonkey is a fork of the popular Greasemonkey extension for Firefox.
People watching this ticket
Referenced by
- 9 Failing unwrapped scripts are executed twice (from [5dfd6fc9fcc60b23084c59007bebcf7462c2e853]) Don't e...