From 5d50f9aec25f8e2c1e2fb78514fa6cf4085ccfb0 Mon Sep 17 00:00:00 2001 From: Brenda Wallace Date: Sun, 28 May 2017 14:08:57 +1200 Subject: [PATCH] DRY the admin controller --- app/controllers/admin_controller.rb | 8 ++------ 1 file changed, 2 insertions(+), 6 deletions(-) diff --git a/app/controllers/admin_controller.rb b/app/controllers/admin_controller.rb index cfbb5c014..0841d5a9b 100644 --- a/app/controllers/admin_controller.rb +++ b/app/controllers/admin_controller.rb @@ -1,16 +1,12 @@ class AdminController < ApplicationController + respond_to :html def index authorize! :manage, :all - respond_to do |format| - format.html # index.html.haml - end end def newsletter authorize! :manage, :all @members = Member.confirmed.wants_newsletter.all - respond_to do |format| - format.html # index.html.haml - end + respond_with @member end end