Named scope with bang

I think it would be great if named scopes had a bang (!) variation which applies to the current scope instead of returning a new scope. This is very useful if you need to apply scopes conditionally like this:

topics = Topic.approved topics.replied! if only_show_replied? topics.scoped! :limit => limit if limit

I would love to get some feedback on this. Would you like to see the same thing? You can find the patch here: http://rails.lighthouseapp.com/projects/8994/tickets/368

Ryan

I haven't tested this, so I can't exactly give it the old +1, but I expect it to come in handy in the future and it seems like a natural fit.

- Trevor