Closed Bug 756514 Opened 12 years ago Closed 12 years ago

Update documentation to reflect that sandbox.importFunction is no longer necessary

Categories

(Core :: XPConnect, defect)

defect
Not set
normal

Tracking

()

RESOLVED FIXED

People

(Reporter: bholley, Unassigned)

Details

(Keywords: dev-doc-complete)

I'm not sure what it used to do, but it doesn't do anything useful now post-compartments. We should update the docs to tell people they can just define the functions directly on the sandbox.
For what it's worth, this was necessary before we had automatic wrappers. Simply doing sandbox.function = chromeFunction was unsafe because there were ways of attacking chrome with the function object (or by passing evil objects to it). Now that we have automatic wrappers, importFunction is no longer necessary.
I just updated https://developer.mozilla.org/en-US/docs/Components.utils.Sandbox - I hope that was the only docs you had in mind, so I'm closing this.
Status: NEW → RESOLVED
Closed: 12 years ago
Resolution: --- → FIXED
I think dev-doc-needed can be removed from here as per markh's comment 2.
You need to log in before you can comment on or make changes to this bug.