lib/active_admin/resource/scopes.rb in activeadmin-1.0.0 vs lib/active_admin/resource/scopes.rb in activeadmin-1.1.0

- old
+ new

@@ -25,10 +25,11 @@ # Create a new scope object for this resource. # If you want to internationalize the scope name, you can add # to your i18n files a key like "active_admin.scopes.scope_method". def scope(*args, &block) - options = args.extract_options! + default_options = {show_count: namespace.scopes_show_count} + options = default_options.merge(args.extract_options!) title = args[0] rescue nil method = args[1] rescue nil options[:localizer] ||= ActiveAdmin::Localizers.resource(self) scope = ActiveAdmin::Scope.new(title, method, options, &block)