weird error popped up with active admin

activeadmin, devise, ruby-on-rails

Solution

It sounds like this is caused by an association that Active Admin is trying to build a filter for, but I'm guessing the association is non-standard. You can see which filters are being built by default with this bit of code:

ActiveAdmin.application.namespaces[:admin].resources[:User].filters

A quick fix would be to remove that filter:

ActiveAdmin.register User do
  # ...

  remove_filter :storage_total_stat

  # ...
end

Problem

I am using active_admin and devise in a project. There is an admin page to invite users that won't even load at all. I have tried removing quite a bit of code to get some clues as to what is going on. All I get is the following error. ``` NoMethodError in Admin/invitations#index Showing /Users/ianseabock/.rvm/gems/ruby-1.9.3-p448/gems/activeadmin-0.6.2/app/views/active_admin/resource/index.html.arb where line #1 raised: undefined method `storage_total_stat_id_eq' for #<MetaSearch::Searches::User:0x007fb9ebde5ce0> Extracted source (around line #1): 1: insert_tag renderer_for(:index) ``` The undefined method "storage_total_stat_id_eq" is no where to be found in the codebase. Any suggestions on what's going on?

Original source