Regarding the ticket https://sourceforge.net/p/turbogears2/tickets/88/
I found that the RestController actually works correctly, but there is
one check that makes it trash away each and every method that is not
registered in a variable called _custom_actions
Applying this change seems to solve the ticket, doesn't break anything
and still protects non exposed methods
def _handle_custom_get(self, state, remainder):
method_name = remainder[-1]
- if method_name not in getattr(self, '_custom_actions', []):
- return
-
It makes me think that it might be some past requirement to prevent
the controller from dispatching private methods,
but as it seems that only methods that have an @expose decorator get
dispatched, there is no requirement for such a thing.
Does anybody know anything about this? Is there any good reason for
custom_actions being there?
I'm going to push it this in the next hours, so let me know if
you know any reason for not doing it.
--
You received this message because you are subscribed to the Google Groups
"TurboGears Trunk" group.
To post to this group, send email to [email protected].
To unsubscribe from this group, send email to
[email protected].
For more options, visit this group at
http://groups.google.com/group/turbogears-trunk?hl=en.