Safer method visibility restoration

This fixes errors when `public` or `private` is redefined, for example as a named_scope on an ActiveRecord model.

/cc @floehopper #109