well, there's no real choice in the model, you only have acting_user.
the point I was making is there is rarely a case where the model
acting_user is not the same User as the controller current_user, since
most time you're checking acting_user it was current_user passed
behind the scenes from controller/view to the model.

On Mar 12, 11:54 am, Owen <[email protected]> wrote:
> Thanks, I think most folks will use "acting_user"
>
> On Mar 12, 1:46 pm, kevinpfromnm <[email protected]> wrote:
>
> > probably the bigger confusion is there's very few cases where the
> > acting_user isn't going to be the current_user.  maybe in some special
> > multipart lifecycle actions but I can't think of any other case that I
> > might use a different acting_user.
>
> > On Mar 12, 7:52 am, Owen <[email protected]> wrote:
>
> > > Think this needs another discussion for all new to Hobo:
>
> > > Here is a post from Tom a while back:
>
> > > Although it is a common source of confusion, it's actually fairly
> > > important to understand the difference between the two concepts, or
> > > you're at risk of messing up your nice MVC separation. current_user
> > > only makes sense in conjunction with the idea of a "current
> > > session",
> > > which only exists in the view and controller layers. That's why in
> > > 'normal' Rails apps you just can't get at that information from the
> > > model.
>
> > > But it struck me that "this model-level action is happening on
> > > behalf
> > > some specific user" is such a fundamental aspect of the kind of apps
> > > we right, that it was a good idea to support this in the model
> > > layer.
>
> > > As Bryan says, it's not _necessarily_ the current_user from the
> > > session. Rather, it's the user who is performing this action - the
> > > acting_user.
>
> > > Sometimes a common source of confusion is a good thing, because
> > > what's
> > > actually going on is a common misconception, and the confusion is an
> > > opportunity to straighten things out.
>
> > > Tom
>
>

-- 
You received this message because you are subscribed to the Google Groups "Hobo 
Users" 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/hobousers?hl=en.

Reply via email to