Bug 1101518 - [Build] Don't rewrite "async" scripts, and fix the skippin...

...g operation
I tried this, this doesn't really work but I don't know why yet... and I found that my fix for scripts.splice doesn't work.. because "idx" is not the right index anymore once we spliced one element :/

The best solution is to use "filter" instead of "forEach" and return true/false if we want to keep the item. We should have done that from the start!

Also I don't see a good way to unit test this using the current unit test framework because we can't easily make various MockDom objects behave differently :/