On Wed Apr 18, 2007 at 08:38:30PM +0200, Jonas Pfenniger wrote:
> 2007/4/18, Thomas Lockney <[EMAIL PROTECTED]>:
> > On 4/18/07, Jonas Pfenniger <[EMAIL PROTECTED]> wrote:
> > > Hi Carmen,
> > >
> > > to avoid patching Camping, I suggest you look into overriding the
> > > "service" method for the target controllers. You can do this in your
> > > main application module or by including a custom module in your
> > > controllers, as you prefer. Let me know if you need more hints.
> >
> > I was going to suggest the same thing, but when I looked at it, it wasn't
> > clear if this would allow for grabbing data like the request headers
> > (allowing you to determine what form the submitted data takes). Based on the
> > code Carmen posted, it looks like the idea is to be able to use the same
> > controllers whether the data comes in from regular requests or as JSON data.
> > Granted, that could still be done in the controllers, but it does end up
> > being a bit less elegant.
> 
> Yes, Camping could probably benefit from some method splitting here. I

perhaps, but

> feel like this method is too big and not really correct. I don't think
> that it should put the posted data in a Tempfile, especially if your
> controller will never make a use of it. I'm not sure it follows the
> RFC too.
> 
> Btw I've spotted some debug line here that could be removed :
> http://code.whytheluckystiff.net/camping/browser/trunk/lib/camping-unabridged.rb#L402

it appears -r188 added the patch i needed to use the service method without the 
unecessary parsing..

/me remembers what i was taught in first grade - always SVN up first!

> 
> -- 
> Cheers,
>   zimbatm
> _______________________________________________
> Camping-list mailing list
> Camping-list@rubyforge.org
> http://rubyforge.org/mailman/listinfo/camping-list
> 
_______________________________________________
Camping-list mailing list
Camping-list@rubyforge.org
http://rubyforge.org/mailman/listinfo/camping-list

Reply via email to