voxdolo/decent_exposure — pull request #42 by kdisneur-silicon (2012-04-03 13:08:29+00:00)
Title: create an alternate find method for default_exposure method

Hi,

We're using `decent_exposure` on a daily basis for our different projects and we really like it and find it very interesting.

However, we'd like the default behavior of `decent_exposure` to do a `find_by` instead of a `find` when used within a Rails project.

Instead of just asking for it, we're making a pull request that lets the developer choose another find behavior without changing the logic of `default_exposure`. The default behavior still calls the `find` method.

class ApplicationController < ActionController::Base
default_exposure_finder :find_by_id
end

We're aware that you don't necessarily agree with the use of other methods like `find_by_id` and that's why we insisted on leaving the default behavior untouched and added a simple alternative for other needs.

We're available for any feedback or question about this topic.

Regards,
The Silicon Salad team.