lib/active_admin/resource/page_presenters.rb in activeadmin-0.6.0 vs lib/active_admin/resource/page_presenters.rb in activeadmin-0.6.1
- old
+ new
@@ -32,12 +32,12 @@
#
# @param [Symbol, String] action The action to get the config for
# @param [String] type The string specified in the presenters index_name method
# @returns [PagePresenter, nil]
def get_page_presenter(action, type=nil)
-
+
if action.to_s == "index" && type && page_presenters[:index].kind_of?(Hash)
- page_presenters[:index][type.to_sym]
+ page_presenters[:index][type.to_sym]
elsif action.to_s == "index" && page_presenters[:index].kind_of?(Hash)
page_presenters[:index].default
else
page_presenters[action.to_sym]
end