Review Board 1.7.22


Actions, selection, and open-views feature issues in a locked domain environment.

Review Request #2994 - Created Dec. 2, 2011 and submitted

Dan Dumont
SHINDIG-1664
Reviewers
shindig
JasonChiang, mhatem, rbaxter, ssievers
shindig
As a general rule, any time anyone is writing a feature using RPC, those endpoints should never expect to get a function (or something that contains a function) as an argument.
The serialization that happens when running with locked domains will null the function argument when (and only when) in locked domains (so jsunit tests will pass).

The check is a bit to expensive to perform for each rpc call so I think people are just going to have to stay sharp.

Side note:
The ugly code you'll run into to get the gadget holder from a site is temporary.  I want to go in later and refactor gadget sites, gadget holders, url sites, and url holders to inherit from a common parent an remove a bunch of the duplication and make the methods make more sense.
Updated jsunit tests, they all pass.

Tested with some gadgets to exercise the open-views, selection, and actions api.
Review request changed
Updated (Dec. 6, 2011, 8:21 p.m.)
Apparently, rpc callbacks should only take 1 parameter.  In the case where these take more than one, I updated the code to pass them as an array and apply them on the original callback.
Ship it!
Posted (Dec. 6, 2011, 8:32 p.m.)
Committed r1211090